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]
Message-ID: <mb61pzft0zk8k.fsf@kernel.org>
Date: Wed, 08 May 2024 10:11:23 +0000
From: Puranjay Mohan <puranjay@...nel.org>
To: Alexei Starovoitov <ast@...nel.org>, Daniel Borkmann
 <daniel@...earbox.net>, Andrii Nakryiko <andrii@...nel.org>, Martin KaFai
 Lau <martin.lau@...ux.dev>, Eduard Zingerman <eddyz87@...il.com>, Song Liu
 <song@...nel.org>, Yonghong Song <yonghong.song@...ux.dev>, John Fastabend
 <john.fastabend@...il.com>, KP Singh <kpsingh@...nel.org>, Stanislav
 Fomichev <sdf@...gle.com>, Hao Luo <haoluo@...gle.com>, Jiri Olsa
 <jolsa@...nel.org>, Zi Shen Lim <zlim.lnx@...il.com>, Catalin Marinas
 <catalin.marinas@....com>, Will Deacon <will@...nel.org>, Mykola Lysenko
 <mykolal@...com>, Shuah Khan <shuah@...nel.org>, bpf@...r.kernel.org,
 linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
 linux-kselftest@...r.kernel.org
Subject: Re: [PATCH bpf-next] bpf, arm64: Add support for lse atomics in
 bpf_arena

Puranjay Mohan <puranjay@...nel.org> writes:

> When LSE atomics are available, BPF atomic instructions are implemented
> as single ARM64 atomic instructions, therefore it is easy to enable
> these in bpf_arena using the currently available exception handling
> setup.
>
> LL_SC atomics use loops and therefore would need more work to enable in
> bpf_arena.
>
> Enable LSE atomics based instructions in bpf_arena and use the
> bpf_jit_supports_insn() callback to reject atomics in bpf_arena if LSE
> atomics are not available.
>
> All atomics and arena_atomics selftests are passing:
>
>   [root@...172-31-2-216 bpf]# ./test_progs -a atomics,arena_atomics
>   #3/1     arena_atomics/add:OK
>   #3/2     arena_atomics/sub:OK
>   #3/3     arena_atomics/and:OK
>   #3/4     arena_atomics/or:OK
>   #3/5     arena_atomics/xor:OK
>   #3/6     arena_atomics/cmpxchg:OK
>   #3/7     arena_atomics/xchg:OK
>   #3       arena_atomics:OK
>   #10/1    atomics/add:OK
>   #10/2    atomics/sub:OK
>   #10/3    atomics/and:OK
>   #10/4    atomics/or:OK
>   #10/5    atomics/xor:OK
>   #10/6    atomics/cmpxchg:OK
>   #10/7    atomics/xchg:OK
>   #10      atomics:OK
>   Summary: 2/14 PASSED, 0 SKIPPED, 0 FAILED

Gentle ping about this,

Thanks,
Puranjay

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ