From: "Alexis Lothoré (eBPF Foundation)" <alexis.lothore@bootlin.com>
To: Andrii Nakryiko <andrii@kernel.org>,
Eduard Zingerman <eddyz87@gmail.com>,
Alexei Starovoitov <ast@kernel.org>,
Daniel Borkmann <daniel@iogearbox.net>,
Martin KaFai Lau <martin.lau@linux.dev>,
Song Liu <song@kernel.org>,
Yonghong Song <yonghong.song@linux.dev>,
John Fastabend <john.fastabend@gmail.com>,
KP Singh <kpsingh@kernel.org>,
Stanislav Fomichev <sdf@fomichev.me>,
Hao Luo <haoluo@google.com>, Jiri Olsa <jolsa@kernel.org>,
Shuah Khan <shuah@kernel.org>
Cc: ebpf@linuxfoundation.org,
"Bastien Curutchet" <bastien.curutchet@bootlin.com>,
"Thomas Petazzoni" <thomas.petazzoni@bootlin.com>,
linux-kernel@vger.kernel.org, bpf@vger.kernel.org,
linux-kselftest@vger.kernel.org,
"Alexis Lothoré (eBPF Foundation)" <alexis.lothore@bootlin.com>
Subject: [PATCH bpf-next 0/4] selftests/bpf: add a new runner for bpftool tests
Date: Wed, 14 Jan 2026 09:59:11 +0100 [thread overview]
Message-ID: <20260114-bpftool-tests-v1-0-cfab1cc9beaf@bootlin.com> (raw)
Hello,
this series is part of the larger effort aiming to convert all
standalone tests to the CI runners so that they are properly executed on
patches submission.
Some of those tests are validating bpftool behavior(test_bpftool_map.sh,
test_bpftool_metadata.sh, test_bpftool_synctypes.py, test_bpftool.py...)
and so they do not integrate well in test_progs. This series proposes to
introduce a new runner to support those tests. This new runner is
heavily inspired from test_progs, with slightly less features.
- First commit move the assert macros exposed by test_progs into a
shared header so that they can be used by the new runner
- Second commit introduces the new runner, as well as a first test
- Third commit adds a second test
- Fourth commit drops the legacy scripts corresponding to those new
tests
The series only adds the runner, but it is not enough to have it running
in CI. The github actions need to be updated both in [1] and [2], and I
am not sure how it si supposed to be contributed (the part needed in [1]
must likely be integrated in the commit that is systematically brought
on top of the bpf-next_base branch). Still, an example of test_bpftool
run can be found in [3], in which I have forked and updated the needed
Github actions ([4])
[1] https://github.com/kernel-patches/bpf.git
[2] https://github.com/libbpf/ci
[3] https://github.com/kernel-patches/bpf/pull/10711
[4] https://github.com/Tropicao/libbpf-ci
Signed-off-by: Alexis Lothoré (eBPF Foundation) <alexis.lothore@bootlin.com>
---
Alexis Lothoré (eBPF Foundation) (4):
bpf/selftests: move assert macros into a dedicated header
bpf/selftests: introduce bptool test runner and a first test
selftests/bpf: add bpftool map manipulations tests
selftests/bpf: remove converted bpftool test scripts
tools/testing/selftests/bpf/.gitignore | 1 +
tools/testing/selftests/bpf/Makefile | 16 +-
tools/testing/selftests/bpf/assert_helpers.h | 231 ++++++++++++
tools/testing/selftests/bpf/bpftool_helpers.c | 114 ++++++
tools/testing/selftests/bpf/bpftool_helpers.h | 19 +
.../testing/selftests/bpf/bpftool_tests/.gitignore | 2 +
.../bpf/bpftool_tests/bpftool_maps_access.c | 370 +++++++++++++++++++
.../selftests/bpf/bpftool_tests/bpftool_metadata.c | 128 +++++++
tools/testing/selftests/bpf/test_bpftool.c | 126 +++++++
tools/testing/selftests/bpf/test_bpftool.h | 36 ++
tools/testing/selftests/bpf/test_bpftool_map.sh | 398 ---------------------
.../testing/selftests/bpf/test_bpftool_metadata.sh | 85 -----
tools/testing/selftests/bpf/test_progs.h | 226 +-----------
13 files changed, 1041 insertions(+), 711 deletions(-)
---
base-commit: 807cd0dc688b0e7314f53dc3a594f247bb3b665b
change-id: 20251212-bpftool-tests-bb165c4cceb8
Best regards,
--
Alexis Lothoré (eBPF Foundation) <alexis.lothore@bootlin.com>
next reply other threads:[~2026-01-14 8:59 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-14 8:59 Alexis Lothoré (eBPF Foundation) [this message]
2026-01-14 8:59 ` [PATCH bpf-next 1/4] bpf/selftests: move assert macros into a dedicated header Alexis Lothoré (eBPF Foundation)
2026-01-15 11:33 ` Quentin Monnet
2026-01-14 8:59 ` [PATCH bpf-next 2/4] bpf/selftests: introduce bptool test runner and a first test Alexis Lothoré (eBPF Foundation)
2026-01-15 11:32 ` Quentin Monnet
2026-01-16 8:14 ` Alexis Lothoré
2026-01-14 8:59 ` [PATCH bpf-next 3/4] selftests/bpf: add bpftool map manipulations tests Alexis Lothoré (eBPF Foundation)
2026-01-15 11:36 ` Quentin Monnet
2026-01-14 8:59 ` [PATCH bpf-next 4/4] selftests/bpf: remove converted bpftool test scripts Alexis Lothoré (eBPF Foundation)
2026-01-15 11:37 ` Quentin Monnet
2026-01-15 17:58 ` [PATCH bpf-next 0/4] selftests/bpf: add a new runner for bpftool tests Andrii Nakryiko
2026-01-16 7:57 ` Alexis Lothoré
2026-01-16 22:20 ` Andrii Nakryiko
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260114-bpftool-tests-v1-0-cfab1cc9beaf@bootlin.com \
--to=alexis.lothore@bootlin.com \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=bastien.curutchet@bootlin.com \
--cc=bpf@vger.kernel.org \
--cc=daniel@iogearbox.net \
--cc=ebpf@linuxfoundation.org \
--cc=eddyz87@gmail.com \
--cc=haoluo@google.com \
--cc=john.fastabend@gmail.com \
--cc=jolsa@kernel.org \
--cc=kpsingh@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=martin.lau@linux.dev \
--cc=sdf@fomichev.me \
--cc=shuah@kernel.org \
--cc=song@kernel.org \
--cc=thomas.petazzoni@bootlin.com \
--cc=yonghong.song@linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox