mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Song Liu <songliubraving@fb.com>
To: Pu Lehui <pulehui@huawei.com>
Cc: Alexei Starovoitov <ast@kernel.org>,
	Daniel Borkmann <daniel@iogearbox.net>,
	Andrii Nakryiko <andrii@kernel.org>, Martin Lau <kafai@fb.com>,
	Yonghong Song <yhs@fb.com>,
	"john.fastabend@gmail.com" <john.fastabend@gmail.com>,
	"kpsingh@kernel.org" <kpsingh@kernel.org>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	"bpf@vger.kernel.org" <bpf@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH bpf-next] bpf: Make some symbols static
Date: Wed, 19 May 2021 17:13:42 +0000	[thread overview]
Message-ID: <10D9E2CC-1EF1-4F67-A5FC-735D1A1F1E40@fb.com> (raw)
In-Reply-To: <20210519064116.240536-1-pulehui@huawei.com>



> On May 18, 2021, at 11:41 PM, Pu Lehui <pulehui@huawei.com> wrote:
> 
> 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 <pulehui@huawei.com>

Acked-by: Song Liu <songliubraving@fb.com>

> ---
> 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
> 


  reply	other threads:[~2021-05-19 17:14 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-19  6:41 Pu Lehui
2021-05-19 17:13 ` Song Liu [this message]
2021-05-19 18:00 ` patchwork-bot+netdevbpf

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=10D9E2CC-1EF1-4F67-A5FC-735D1A1F1E40@fb.com \
    --to=songliubraving@fb.com \
    --cc=andrii@kernel.org \
    --cc=ast@kernel.org \
    --cc=bpf@vger.kernel.org \
    --cc=daniel@iogearbox.net \
    --cc=john.fastabend@gmail.com \
    --cc=kafai@fb.com \
    --cc=kpsingh@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pulehui@huawei.com \
    --cc=yhs@fb.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®