From: Zhu Yanjun <yanjun.zhu@linux.dev>
To: jgg@ziepe.ca, leon@kernel.org, shuah@kernel.org,
zyjzyj2000@gmail.com, linux-rdma@vger.kernel.org,
linux-kselftest@vger.kernel.org, yanjun.zhu@linux.dev
Subject: [PATCH v2 0/2] selftests/rdma: Add an eBPF-based testcase using netkit for RXE
Date: Mon, 19 Oct 2026 14:38:19 -0700 [thread overview]
Message-ID: <20261019213821.44842-1-yanjun.zhu@linux.dev> (raw)
Add a new self-test case to verify RXE (Soft-RoCE) traffic using
netkit virtual interfaces and an eBPF tcx ingress program to dump
and parse RDMA transport headers (BTH, etc.).
The test results:
# make -C tools/testing/selftests/ TARGETS=rdma run_tests
make: Entering directory '/root/linux/tools/testing/selftests'
clang -g -O2 -target bpf -D__TARGET_ARCH_x86 -I../../../../usr/include -I../../../../include/uapi -I../bpf -I/root/linux/tools/testing/selftests/rdma -c rxe_pkg_kernel_dump.c -o /root/linux/tools/testing/selftests/rdma/rxe_pkg_kernel_dump.o
bpftool gen skeleton /root/linux/tools/testing/selftests/rdma/rxe_pkg_kernel_dump.o > /root/linux/tools/testing/selftests/rdma/rxe_pkg_kernel.skel.h
gcc -D_GNU_SOURCE= -I/root/linux/tools/testing/selftests/../../../tools/testing/selftests -g -Wall -I../../../../usr/include -I../../../../include/uapi -I../bpf -I/root/linux/tools/testing/selftests/rdma rxe_pkg_user_dump.c -lbpf -lelf -lz -o /root/linux/tools/testing/selftests/rdma/rxe_netkit_dump
# timeout set to 45
# selftests: rdma: rxe_rping_between_netns.sh
# client DISCONNECT EVENT...
ok 1 selftests: rdma: rxe_rping_between_netns.sh
# timeout set to 45
# selftests: rdma: rxe_ipv6.sh
ok 2 selftests: rdma: rxe_ipv6.sh
# timeout set to 45
# selftests: rdma: rxe_socket_with_netns.sh
ok 3 selftests: rdma: rxe_socket_with_netns.sh
# timeout set to 45
# selftests: rdma: rxe_test_NETDEV_UNREGISTER.sh
ok 4 selftests: rdma: rxe_test_NETDEV_UNREGISTER.sh
# timeout set to 45
# selftests: rdma: rxe_sent_rcvd_bytes.sh
# server DISCONNECT EVENT...
# wait for RDMA_READ_ADV state 10
# client DISCONNECT EVENT...
ok 5 selftests: rdma: rxe_sent_rcvd_bytes.sh
# timeout set to 45
# selftests: rdma: rxe_netns_names.sh
# 1..0 # SKIP rdma netns exclusive mode is not supported
ok 6 selftests: rdma: rxe_netns_names.sh # SKIP
# timeout set to 45
# selftests: rdma: rxe_pkg_netkit.sh
# server DISCONNECT EVENT...
# wait for RDMA_READ_ADV state 10
# ./rxe_pkg_netkit.sh: line 28: 9866 Killed "$CUR_WD/rxe_netkit_dump"
ok 7 selftests: rdma: rxe_pkg_netkit.sh
make: Leaving directory '/root/linux/tools/testing/selftests'
---
V1 - > V2: Fix problems from sashiko
---
Zhu Yanjun (2):
selftests/rdma: Introduce eBPF kernel and user dump utilities for RXE
selftests/rdma: Add netkit-based automated test script for RXE
tools/testing/selftests/rdma/Makefile | 23 +-
tools/testing/selftests/rdma/config | 3 +
.../selftests/rdma/rxe_pkg_kernel_dump.c | 62 +
.../testing/selftests/rdma/rxe_pkg_netkit.sh | 63 +
.../selftests/rdma/rxe_pkg_user_dump.c | 1275 +++++++++++++++++
5 files changed, 1425 insertions(+), 1 deletion(-)
create mode 100644 tools/testing/selftests/rdma/rxe_pkg_kernel_dump.c
create mode 100755 tools/testing/selftests/rdma/rxe_pkg_netkit.sh
create mode 100644 tools/testing/selftests/rdma/rxe_pkg_user_dump.c
--
2.54.0
next reply other threads:[~2026-10-19 21:38 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-19 21:38 Zhu Yanjun [this message]
2026-10-19 21:38 ` [PATCH v2 1/2] selftests/rdma: Introduce eBPF kernel and user dump utilities for RXE Zhu Yanjun
2026-10-19 21:38 ` [PATCH v2 2/2] selftests/rdma: Add netkit-based automated test script " Zhu Yanjun
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=20261019213821.44842-1-yanjun.zhu@linux.dev \
--to=yanjun.zhu@linux.dev \
--cc=jgg@ziepe.ca \
--cc=leon@kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=linux-rdma@vger.kernel.org \
--cc=shuah@kernel.org \
--cc=zyjzyj2000@gmail.com \
/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