diff options
author | Magnus Karlsson <magnus.karlsson@intel.com> | 2023-09-14 11:48:53 +0300 |
---|---|---|
committer | Alexei Starovoitov <ast@kernel.org> | 2023-09-14 19:47:55 +0300 |
commit | c53dab7d39abd46901122fa47d3dce3b482d9c54 (patch) | |
tree | 458de07367891d4c5181c8f2dbe24de9e4984d4b /tools/testing/selftests/bpf/xsk_prereqs.sh | |
parent | f20fbcd077eb8f46d6deee46e345fefb1130a181 (diff) | |
download | linux-c53dab7d39abd46901122fa47d3dce3b482d9c54.tar.xz |
selftests/xsk: add option that lists all tests
Add a command line option (-l) that lists all the tests. The number
before the test will be used in the next commit for specifying a
single test to run. Here is an example of the output:
Tests:
0: SEND_RECEIVE
1: SEND_RECEIVE_2K_FRAME
2: SEND_RECEIVE_SINGLE_PKT
3: POLL_RX
4: POLL_TX
5: POLL_RXQ_FULL
6: POLL_TXQ_FULL
7: SEND_RECEIVE_UNALIGNED
:
:
Signed-off-by: Magnus Karlsson <magnus.karlsson@intel.com>
Link: https://lore.kernel.org/r/20230914084900.492-7-magnus.karlsson@gmail.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'tools/testing/selftests/bpf/xsk_prereqs.sh')
-rwxr-xr-x | tools/testing/selftests/bpf/xsk_prereqs.sh | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/tools/testing/selftests/bpf/xsk_prereqs.sh b/tools/testing/selftests/bpf/xsk_prereqs.sh index 29175682c44d..47c7b8064f38 100755 --- a/tools/testing/selftests/bpf/xsk_prereqs.sh +++ b/tools/testing/selftests/bpf/xsk_prereqs.sh @@ -83,9 +83,11 @@ exec_xskxceiver() fi ./${XSKOBJ} -i ${VETH0} -i ${VETH1} ${ARGS} - retval=$? - test_status $retval "${TEST_NAME}" - statusList+=($retval) - nameList+=(${TEST_NAME}) + + if [[ $list -ne 1 ]]; then + test_status $retval "${TEST_NAME}" + statusList+=($retval) + nameList+=(${TEST_NAME}) + fi } |