Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

selftests/bpf: Upon failures, exit with code 1 in test_xsk.sh

Currently, even if some subtests fails, the end result will still yield
"ok 1 selftests: bpf: test_xsk.sh". Fix it by exiting with 1 if there are
any failures.

Signed-off-by: Ricardo B. Marlière <rbm@suse.com>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Acked-by: Magnus Karlsson <magnus.karlsson@intel.com>
Link: https://lore.kernel.org/bpf/20250828-selftests-bpf-test_xsk_ret-v1-1-e6656c01f397@suse.com

authored by

Ricardo B. Marlière and committed by
Andrii Nakryiko
2a912258 e4980fa6

+2
+2
tools/testing/selftests/bpf/test_xsk.sh
··· 241 241 242 242 if [ $failures -eq 0 ]; then 243 243 echo "All tests successful!" 244 + else 245 + exit 1 244 246 fi