From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752847AbeAQLXL (ORCPT + 1 other); Wed, 17 Jan 2018 06:23:11 -0500 Received: from youngberry.canonical.com ([91.189.89.112]:56831 "EHLO youngberry.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751261AbeAQLXI (ORCPT ); Wed, 17 Jan 2018 06:23:08 -0500 From: Colin King To: Jiri Pirko , "David S . Miller" , netdev@vger.kernel.org Cc: kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH][devlink-next] devlink: make functions a couple of new functions static Date: Wed, 17 Jan 2018 11:23:03 +0000 Message-Id: <20180117112303.20149-1-colin.king@canonical.com> X-Mailer: git-send-email 2.15.1 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Return-Path: From: Colin Ian King The functions devlink_resource_find and devlink_resource_validate_children are local to the source and do not need to be in global scope, so make them static. Cleans up sparse warnings: symbol 'devlink_resource_find' was not declared. Should it be static? warning: symbol 'devlink_resource_validate_children' was not declared. Should it be static? Signed-off-by: Colin Ian King --- net/core/devlink.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/net/core/devlink.c b/net/core/devlink.c index dd7d6dd07bfb..66d36705fb9d 100644 --- a/net/core/devlink.c +++ b/net/core/devlink.c @@ -2294,7 +2294,7 @@ static int devlink_nl_cmd_dpipe_table_counters_set(struct sk_buff *skb, counters_enable); } -struct devlink_resource * +static struct devlink_resource * devlink_resource_find(struct devlink *devlink, struct devlink_resource *resource, u64 resource_id) { @@ -2319,7 +2319,8 @@ devlink_resource_find(struct devlink *devlink, return NULL; } -void devlink_resource_validate_children(struct devlink_resource *resource) +static void +devlink_resource_validate_children(struct devlink_resource *resource) { struct devlink_resource *child_resource; bool size_valid = true; -- 2.15.1