BPF List
 help / color / mirror / Atom feed
* [PATCH bpf-next 0/2] selftests/bpf: Skip libarena when arena spin locks are unsupported
@ 2026-10-09  1:49 Qiliang Yuan
  2026-10-09  1:49 ` [PATCH bpf-next 1/2] selftests/bpf: Return the lock error from buddy_init() of libarena Qiliang Yuan
  2026-10-09  1:49 ` [PATCH bpf-next 2/2] selftests/bpf: Skip libarena on kernels with too many possible CPUs Qiliang Yuan
  0 siblings, 2 replies; 6+ messages in thread
From: Qiliang Yuan @ 2026-10-09  1:49 UTC (permalink / raw)
  To: Alexei Starovoitov, Daniel Borkmann, Andrii Nakryiko,
	Eduard Zingerman, Kumar Kartikeya Dwivedi, Martin KaFai Lau,
	Song Liu, Yonghong Song, Jiri Olsa, Emil Tsalapatis,
	Ihor Solodrai, Shuah Khan
  Cc: bpf, linux-kselftest, linux-kernel, Qiliang Yuan

serial_test_libarena runs the test programs of libarena, whose buddy
allocator serializes its operations with an arena spin lock.

arena_spin_lock() fails with -EOPNOTSUPP on kernels built with more
than 1024 possible CPUs, as distributions commonly configure them.
buddy_init() reports that as -EINVAL, and every test then fails at
arena_buddy_reset.

Patch 1 makes buddy_init() return the error of the lock, patch 2 skips
the tests when resetting the allocator fails with -EOPNOTSUPP.

Signed-off-by: Qiliang Yuan <odys.yuan@gmail.com>
---
Qiliang Yuan (2):
      selftests/bpf: Return the lock error from buddy_init() of libarena
      selftests/bpf: Skip libarena on kernels with too many possible CPUs

 tools/testing/selftests/bpf/libarena/src/buddy.bpf.c | 5 +++--
 tools/testing/selftests/bpf/prog_tests/libarena.c    | 9 +++++++++
 2 files changed, 12 insertions(+), 2 deletions(-)
---
base-commit: e1d84a37cba984388988d2f1ddc84561413f0db2
change-id: 20261009-selftests-bpf-libarena-nr-cpus-50fc5dd00fe2

Best regards,
-- 
Qiliang Yuan <odys.yuan@gmail.com>


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2026-10-09  2:37 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-09  1:49 [PATCH bpf-next 0/2] selftests/bpf: Skip libarena when arena spin locks are unsupported Qiliang Yuan
2026-10-09  1:49 ` [PATCH bpf-next 1/2] selftests/bpf: Return the lock error from buddy_init() of libarena Qiliang Yuan
2026-10-09  2:00   ` sashiko-bot
2026-10-09  2:37   ` bot+bpf-ci
2026-10-09  1:49 ` [PATCH bpf-next 2/2] selftests/bpf: Skip libarena on kernels with too many possible CPUs Qiliang Yuan
2026-10-09  2:37   ` bot+bpf-ci

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox