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] [day] [month] [year] [list]
Date:   Wed, 22 Feb 2023 20:31:22 +0100
From:   Daniel Borkmann <daniel@...earbox.net>
To:     Viresh Kumar <viresh.kumar@...aro.org>,
        Alexei Starovoitov <ast@...nel.org>,
        John Fastabend <john.fastabend@...il.com>,
        Andrii Nakryiko <andrii@...nel.org>,
        Martin KaFai Lau <martin.lau@...ux.dev>,
        Song Liu <song@...nel.org>, Yonghong Song <yhs@...com>,
        KP Singh <kpsingh@...nel.org>,
        Stanislav Fomichev <sdf@...gle.com>,
        Hao Luo <haoluo@...gle.com>, Jiri Olsa <jolsa@...nel.org>,
        Thomas Gleixner <tglx@...utronix.de>,
        Dave Hansen <dave.hansen@...ux.intel.com>
Cc:     Linus Torvalds <torvalds@...ux-foundation.org>,
        bpf@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] bpf: Fix undeclared function 'barrier_nospec' warning

On 2/22/23 9:24 AM, Viresh Kumar wrote:
> Add the missing header for architectures that don't define
> the barrier_nospec() macro. The nospec.h header is added after the
> inclusion of barrier.h to avoid redefining the macro for architectures
> that already define barrier_nospec() in their respective barrier.h
> headers.
> 
> Fixes: 74e19ef0ff80 ("uaccess: Add speculation barrier to copy_from_user()")
> Signed-off-by: Viresh Kumar <viresh.kumar@...aro.org>
> ---
> Linus's master branch fails currently to build for arm64 without this commit.
> 
>   kernel/bpf/core.c | 2 ++
>   1 file changed, 2 insertions(+)
> 
> diff --git a/kernel/bpf/core.c b/kernel/bpf/core.c
> index 933869983e2a..92aeb388e422 100644
> --- a/kernel/bpf/core.c
> +++ b/kernel/bpf/core.c
> @@ -38,6 +38,8 @@
>   #include <linux/memcontrol.h>
>   
>   #include <asm/barrier.h>
> +#include <linux/nospec.h>
> +

nit: The asm/barrier.h include could have just been removed. linux/nospec.h
internally includes asm/barrier.h already.

>   #include <asm/unaligned.h>
>   
>   /* Registers */
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ