lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 27 Mar 2020 21:34:05 +0100
From:   Daniel Borkmann <daniel@...earbox.net>
To:     Jean-Philippe Menil <jpmenil@...il.com>,
        alexei.starovoitov@...il.com
Cc:     kernel-janitors@...r.kernel.org,
        "David S. Miller" <davem@...emloft.net>,
        Jakub Kicinski <kuba@...nel.org>,
        Alexei Starovoitov <ast@...nel.org>,
        Martin KaFai Lau <kafai@...com>,
        Song Liu <songliubraving@...com>, Yonghong Song <yhs@...com>,
        Andrii Nakryiko <andriin@...com>, netdev@...r.kernel.org,
        bpf@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v3] bpf: fix build warning - missing prototype

On 3/27/20 8:55 AM, Jean-Philippe Menil wrote:
> Fix build warnings when building net/bpf/test_run.o with W=1 due
> to missing prototype for bpf_fentry_test{1..6}.
> 
> Instead of declaring prototypes, turn off warnings with
> __diag_{push,ignore,pop} as pointed by Alexei.
> 
> Signed-off-by: Jean-Philippe Menil <jpmenil@...il.com>

Looks better, but this doesn't apply cleanly. Please respin to latest bpf-next tree, thanks.

> ---
>   net/bpf/test_run.c | 5 +++++
>   1 file changed, 5 insertions(+)
> 
> diff --git a/net/bpf/test_run.c b/net/bpf/test_run.c
> index d555c0d8657d..cc1592413fc3 100644
> --- a/net/bpf/test_run.c
> +++ b/net/bpf/test_run.c
> @@ -113,6 +113,9 @@ static int bpf_test_finish(const union bpf_attr *kattr,
>    * architecture dependent calling conventions. 7+ can be supported in the
>    * future.
>    */
> +__diag_push();
> +__diag_ignore(GCC, 8, "-Wmissing-prototypes",
> +	      "Global functions as their definitions will be in vmlinux BTF);
>   int noinline bpf_fentry_test1(int a)
>   {
>   	return a + 1;
> @@ -143,6 +146,8 @@ int noinline bpf_fentry_test6(u64 a, void *b, short c, int d, void *e, u64 f)
>   	return a + (long)b + c + d + (long)e + f;
>   }
>   
> +__diag_pop();
> +
>   static void *bpf_test_init(const union bpf_attr *kattr, u32 size,
>   			   u32 headroom, u32 tailroom)
>   {
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ