Re: [PATCH ipsec-next v1 5/7] bpf: selftests: test_tunnel: Use vmlinux.h declarations

2023-11-25 Thread Daniel Xu
Hi Yonghong, On Sat, Nov 25, 2023 at 04:34:36PM -0800, Yonghong Song wrote: > > On 11/22/23 1:20 PM, Daniel Xu wrote: > > vmlinux.h declarations are more ergnomic, especially when working with > > kfuncs. The uapi headers are often incomplete for kfunc definitions. > > > > Co-developed-by:

Re: [PATCH ipsec-next v1 6/7] bpf: selftests: test_tunnel: Disable CO-RE relocations

2023-11-25 Thread Yonghong Song
On 11/25/23 7:54 PM, Alexei Starovoitov wrote: On Sat, Nov 25, 2023 at 4:52 PM Yonghong Song wrote: diff --git a/tools/testing/selftests/bpf/progs/test_tunnel_kern.c b/tools/testing/selftests/bpf/progs/test_tunnel_kern.c index 3065a716544d..ec7e04e012ae 100644 ---

Re: [PATCH ipsec-next v1 6/7] bpf: selftests: test_tunnel: Disable CO-RE relocations

2023-11-25 Thread Alexei Starovoitov
On Sat, Nov 25, 2023 at 4:52 PM Yonghong Song wrote: > > > > > diff --git a/tools/testing/selftests/bpf/progs/test_tunnel_kern.c > > b/tools/testing/selftests/bpf/progs/test_tunnel_kern.c > > index 3065a716544d..ec7e04e012ae 100644 > > --- a/tools/testing/selftests/bpf/progs/test_tunnel_kern.c >

Re: [PATCH ipsec-next v1 6/7] bpf: selftests: test_tunnel: Disable CO-RE relocations

2023-11-25 Thread Yonghong Song
On 11/22/23 1:20 PM, Daniel Xu wrote: Switching to vmlinux.h definitions seems to make the verifier very unhappy with bitfield accesses. The error is: ; md.u.md2.dir = direction; 33: (69) r1 = *(u16 *)(r2 +11) misaligned stack access off (0x0; 0x0)+-64+11 size 2 It looks like

Re: [PATCH ipsec-next v1 5/7] bpf: selftests: test_tunnel: Use vmlinux.h declarations

2023-11-25 Thread Yonghong Song
On 11/22/23 1:20 PM, Daniel Xu wrote: vmlinux.h declarations are more ergnomic, especially when working with kfuncs. The uapi headers are often incomplete for kfunc definitions. Co-developed-by: Antony Antony Signed-off-by: Antony Antony Signed-off-by: Daniel Xu ---

Re: [PATCH v3 03/25] arm64: cpufeature: add Permission Overlay Extension cpucap

2023-11-25 Thread Mark Brown
On Fri, Nov 24, 2023 at 04:34:48PM +, Joey Gouly wrote: > This indicates if the system supports POE. This is a CPUCAP_BOOT_CPU_FEATURE > as the boot CPU will enable POE if it has it, so secondary CPUs must also > have this feature. > > Add a new config option: ARM64_POE For bisection

Re: [PATCH v3 05/25] arm64: context switch POR_EL0 register

2023-11-25 Thread Mark Brown
On Fri, Nov 24, 2023 at 04:34:50PM +, Joey Gouly wrote: > +static void flush_poe(void) > +{ > + if (system_supports_poe()) > + write_sysreg_s(POR_EL0_INIT, SYS_POR_EL0); > +} Here we have no isb()... > +static void permission_overlay_switch(struct task_struct *next) > +{ > +

[PATCH bpf-next v5 3/3] selftests/bpf: Use pkg-config for libelf

2023-11-25 Thread Akihiko Odaki
When linking statically, libraries may require other dependencies to be included to ld flags. In particular, libelf may require libzstd. Use pkg-config to determine such dependencies. Signed-off-by: Akihiko Odaki --- tools/testing/selftests/bpf/Makefile | 8 ++-- 1 file changed, 6

[PATCH bpf-next v5 2/3] selftests/bpf: Override PKG_CONFIG for static builds

2023-11-25 Thread Akihiko Odaki
A library may need to depend on additional archive files for static builds so pkg-config should be instructed to list them. Signed-off-by: Akihiko Odaki --- tools/testing/selftests/bpf/README.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH bpf-next v5 1/3] selftests/bpf: Choose pkg-config for the target

2023-11-25 Thread Akihiko Odaki
pkg-config is used to build sign-file executable. It should use the library for the target instead of the host as it is called during tests. Signed-off-by: Akihiko Odaki --- tools/testing/selftests/bpf/Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git

[PATCH bpf-next v5 0/3] selftests/bpf: Use pkg-config to determine ld flags

2023-11-25 Thread Akihiko Odaki
When linking statically, libraries may require other dependencies to be included to ld flags. In particular, libelf may require libzstd. Use pkg-config to determine such dependencies. V4 -> V5: Introduced variables LIBELF_CFLAGS and LIBELF_LIBS. (Daniel Borkmann) Added patch