selftests: mptcp: relax conditions in SYN_TX validation
Subsystems (3)
PATCH 2/3 selftests: mptcp: relax conditions in SYN_TX validation
From: Gang Yan <[email protected]>
In ADD_ADDR timeout test cases, the syn_tx MIB counter is not an accurate number. This patch introduces '+n' to 'join_syn_tx' to relax the strict condition.
Signed-off-by Gang Yan <[email protected]>
--- tools/testing/selftests/net/mptcp/mptcp_join.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-)
tools/testing/selftests/net/mptcp/mptcp_join.sh +8 -1
@@ -1361,13 +1361,20 @@ chk_join_tx_nr() local create=${join_create_err:-0} local bind=${join_bind_err:-0} local connect=${join_connect_err:-0} + local allow_multi_syn_tx=0 local rc=${KSFT_PASS} local count + if [[ "${join_syn_tx}" = "+"* ]]; then + allow_multi_syn_tx=1 + syn_tx=${join_syn_tx:1} + fi + count=$(mptcp_lib_get_counter ${ns2} "MPTcpExtMPJoinSynTx") if [ -z "$count" ]; then rc=${KSFT_SKIP} - elif [ "$count" != "$syn_tx" ]; then + elif { [ "$count" != $syn_tx ] && [ $allow_multi_syn_tx -eq 0 ]; } || + { [ "$count" -lt $syn_tx ] && [ $allow_multi_syn_tx -eq 1 ]; }; then rc=${KSFT_FAIL} print_check "syn tx" fail_test "got $count JOIN[s] syn tx expected $syn_tx"
Signature · 1 line
2.25.1
Matthieu Baerts
maintainerHi Gang,
Quoted 4 lines · Gang Yan
From: Gang Yan <[email protected]>
In
ADD_ADDRtimeout test cases, thesyn_txMIB counter is not an accurate number.
Please explain why this counter is not an accurate number.
When you say that, it sounds like there is something to fix in the kernel, but not in the tests.
(It might help to squash this patch with the next one, or to rephrase it to say that a future test will do some retransmissions)
Quoted 2 lines
This patch introduces '+n' to '
join_syn_tx'
to relax the strict condition.
(...)
Cheers,
Matt
Signature · 1 line
Sponsored by the NGI0 Core fund.