Extend add_addr_ports_tests with IPv6 signaling cases that exercise
ADD_ADDR tx-space shortage when tcp_timestamps are enabled.
Add one case to verify PM still progresses to later signal endpoints
after the first one is dropped.
This covers both failure accounting and the non-blocking behavior of
the announce list after a tx-space drop on pure ACK.
Signed-off-by: Li Xiasong <lixiasong1@huawei.com>
---
.../testing/selftests/net/mptcp/mptcp_join.sh | 31 +++++++++++++++++++
1 file changed, 31 insertions(+)
diff --git a/tools/testing/selftests/net/mptcp/mptcp_join.sh b/tools/testing/selftests/net/mptcp/mptcp_join.sh
index beec41f6662a..5acd12021e6e 100755
--- a/tools/testing/selftests/net/mptcp/mptcp_join.sh
+++ b/tools/testing/selftests/net/mptcp/mptcp_join.sh
@@ -1828,6 +1828,22 @@ chk_add_tx_nr()
fi
}
+chk_add_drop_tx_nr()
+{
+ local drop_tx_nr=$1
+ local count
+
+ print_check "add addr tx drop"
+ count=$(mptcp_lib_get_counter ${ns1} "MPTcpExtAddAddrTxDrop")
+ if [ -z "$count" ]; then
+ print_skip
+ elif [ "$count" != "$drop_tx_nr" ]; then
+ fail_test "got $count ADD_ADDR drop[s] TX, expected $drop_tx_nr"
+ else
+ print_ok
+ fi
+}
+
chk_rm_nr()
{
local rm_addr_nr=$1
@@ -3278,6 +3294,21 @@ add_addr_ports_tests()
chk_mpc_endp_attempt ${retl} 1
fi
+
+ # first signal address drops, second one still progresses
+ if reset "signal addr list progresses after tx drop"; then
+ pm_nl_set_limits $ns1 0 2
+ pm_nl_set_limits $ns2 1 0
+ ip netns exec $ns1 sysctl -q net.ipv4.tcp_timestamps=1
+ ip netns exec $ns2 sysctl -q net.ipv4.tcp_timestamps=1
+
+ pm_nl_add_endpoint $ns1 dead:beef:2::1 flags signal port 10100
+ pm_nl_add_endpoint $ns1 dead:beef:3::1 flags signal
+ run_tests $ns1 $ns2 dead:beef:1::1
+ chk_add_drop_tx_nr 1
+ chk_add_tx_nr 1 1
+ chk_add_nr 1 1 0
+ fi
}
bind_tests()
--
2.34.1
Hi Li,
On 07/05/2026 14:52, Li Xiasong wrote:
> Extend add_addr_ports_tests with IPv6 signaling cases that exercise
> ADD_ADDR tx-space shortage when tcp_timestamps are enabled.
>
> Add one case to verify PM still progresses to later signal endpoints
> after the first one is dropped.
>
> This covers both failure accounting and the non-blocking behavior of
> the announce list after a tx-space drop on pure ACK.
>
> Signed-off-by: Li Xiasong <lixiasong1@huawei.com>
> ---
> .../testing/selftests/net/mptcp/mptcp_join.sh | 31 +++++++++++++++++++
> 1 file changed, 31 insertions(+)
>
> diff --git a/tools/testing/selftests/net/mptcp/mptcp_join.sh b/tools/testing/selftests/net/mptcp/mptcp_join.sh
> index beec41f6662a..5acd12021e6e 100755
> --- a/tools/testing/selftests/net/mptcp/mptcp_join.sh
> +++ b/tools/testing/selftests/net/mptcp/mptcp_join.sh
(...)
> @@ -3278,6 +3294,21 @@ add_addr_ports_tests()
>
> chk_mpc_endp_attempt ${retl} 1
> fi
> +
> + # first signal address drops, second one still progresses
> + if reset "signal addr list progresses after tx drop"; then
> + pm_nl_set_limits $ns1 0 2
> + pm_nl_set_limits $ns2 1 0
> + ip netns exec $ns1 sysctl -q net.ipv4.tcp_timestamps=1
> + ip netns exec $ns2 sysctl -q net.ipv4.tcp_timestamps=1
> +
> + pm_nl_add_endpoint $ns1 dead:beef:2::1 flags signal port 10100
> + pm_nl_add_endpoint $ns1 dead:beef:3::1 flags signal
> + run_tests $ns1 $ns2 dead:beef:1::1
> + chk_add_drop_tx_nr 1
> + chk_add_tx_nr 1 1
It would be good to call chk_add_drop_tx_nr from chk_add_tx_nr, similar
to what is done with chk_join_tx_nr from chk_join_nr. For example, by
default, assuming there is no drop, except when add_addr_drop_tx_nr=X is
passed when calling chk_add_tx_nr. Or as a new optional argument for
chk_add_tx_nr.
But that's more mptcp-next material, so I'm not going to block this
patch for that! But if you are whiling to add this, don't hesitate to :)
> + chk_add_nr 1 1 0
> + fi
> }
>
> bind_tests()
Cheers,
Matt
--
Sponsored by the NGI0 Core fund.
© 2016 - 2026 Red Hat, Inc.