Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp1721319pxj; Wed, 19 May 2021 12:18:33 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzd5NXe11IbFGpLOyGcv6W826vuEN9BuYnS9twB+mWrJ0NR4NjM+UsJbWAQr4hZ3d22mhpW X-Received: by 2002:a17:907:76e8:: with SMTP id kg8mr688048ejc.130.1621451913618; Wed, 19 May 2021 12:18:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621451913; cv=none; d=google.com; s=arc-20160816; b=cq8kcj2G1vHHkFF8jx4rsz2hd5BgHXz0hTqI1QaF3Reyw7YT42qb0DksHVntD91qC0 tOG1LnH+a0J3RqV095CLGbh5ZUQlkFWNFtSqcMKkjsIgE+fLl4gUcA5vCM2xAfqG25+H 2EukWMTaj3RK0M9KvjgdCmHvAQlw/IFGE52M1exxW79IWhY4Fbimw3/rLLdWTgCtXRgx yTDQko1xXCMjkSjOLvBL8Wa/83Mu9PwZfEfoJGVioVjPmtTb6yWRa4rpZe7fymh7jVlt oix7RhRGWgC0MrttlN3Mo/twH1q73Q22zE1l++CM2eBp/iwg34/S6nuqshNqN6HI3qpL YsWQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from; bh=3n7I5UNddOIGwVriFgRdw1+kFq7KbWbyWCLEdSDmRNs=; b=SmKs9wTG8GhMCyhUhXVuNlZ1+/zlSQXlvzYkgK8CEH7wUW6sw9QL1q5+Q4bofavae0 GZyKn34VneXoOGlsTf922izYUTeCLHShsxwnpmy1AaJgSmRbibq10+fPIHlEx1rewIVu GAIu1VeO8LMOinIv9ibbuIDB+Yw1msRm/vTi8OQqU2HhsYFEpu20Dn4P6qYQqXr1rrIz CDGgqxV2osg+q36c/5hh9si93cr/F0bSmhoz7YtyskxzRcW+51vQcQ2rHKAMwZJBYTlC rsGw23N7mnnUJun5dASVjS79iJwAXYzwX2h+xxd+dJ6mQk4bexLB+xBDFWGTEVC0RifP 5tNA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w15si512430ejb.550.2021.05.19.12.18.07; Wed, 19 May 2021 12:18:33 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231613AbhESGmH (ORCPT + 99 others); Wed, 19 May 2021 02:42:07 -0400 Received: from szxga04-in.huawei.com ([45.249.212.190]:4675 "EHLO szxga04-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230154AbhESGmG (ORCPT ); Wed, 19 May 2021 02:42:06 -0400 Received: from dggems704-chm.china.huawei.com (unknown [172.30.72.60]) by szxga04-in.huawei.com (SkyGuard) with ESMTP id 4FlNTz3gG6z1BNss; Wed, 19 May 2021 14:37:59 +0800 (CST) Received: from dggpemm500019.china.huawei.com (7.185.36.180) by dggems704-chm.china.huawei.com (10.3.19.181) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Wed, 19 May 2021 14:40:45 +0800 Received: from ubuntu1804.huawei.com (10.67.174.98) by dggpemm500019.china.huawei.com (7.185.36.180) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Wed, 19 May 2021 14:40:45 +0800 From: Pu Lehui To: , , , , , , , CC: , , , Subject: [PATCH bpf-next] bpf: Make some symbols static Date: Wed, 19 May 2021 14:41:16 +0800 Message-ID: <20210519064116.240536-1-pulehui@huawei.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.67.174.98] X-ClientProxiedBy: dggems701-chm.china.huawei.com (10.3.19.178) To dggpemm500019.china.huawei.com (7.185.36.180) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The sparse tool complains as follows: kernel/bpf/syscall.c:4567:29: warning: symbol 'bpf_sys_bpf_proto' was not declared. Should it be static? kernel/bpf/syscall.c:4592:29: warning: symbol 'bpf_sys_close_proto' was not declared. Should it be static? This symbol is not used outside of syscall.c, so marks it static. Signed-off-by: Pu Lehui --- kernel/bpf/syscall.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel/bpf/syscall.c b/kernel/bpf/syscall.c index 2361d97e2c67..73d15bc62d8c 100644 --- a/kernel/bpf/syscall.c +++ b/kernel/bpf/syscall.c @@ -4564,7 +4564,7 @@ BPF_CALL_3(bpf_sys_bpf, int, cmd, void *, attr, u32, attr_size) return __sys_bpf(cmd, KERNEL_BPFPTR(attr), attr_size); } -const struct bpf_func_proto bpf_sys_bpf_proto = { +static const struct bpf_func_proto bpf_sys_bpf_proto = { .func = bpf_sys_bpf, .gpl_only = false, .ret_type = RET_INTEGER, @@ -4589,7 +4589,7 @@ BPF_CALL_1(bpf_sys_close, u32, fd) return close_fd(fd); } -const struct bpf_func_proto bpf_sys_close_proto = { +static const struct bpf_func_proto bpf_sys_close_proto = { .func = bpf_sys_close, .gpl_only = false, .ret_type = RET_INTEGER, -- 2.17.1