]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
selftests: mptcp: validate ADD_ADDRv6 + TS + port
authorMatthieu Baerts (NGI0) <matttbe@kernel.org>
Fri, 5 Jun 2026 09:21:51 +0000 (19:21 +1000)
committerJakub Kicinski <kuba@kernel.org>
Thu, 11 Jun 2026 22:33:38 +0000 (15:33 -0700)
This validates the feature added by parent commit, where it is now
possible to send an ADD_ADDR with a v6 IP address and a port number,
while the connection is using TCP Timestamps.

This test is simply a copy of the previous one: "signal address with
port", but using IPv6 addresses. This test is only executed if the
add_addr_v6_port_drop_ts sysctl knob is available. If not, it means the
kernel doesn't support this feature.

Reviewed-by: Mat Martineau <martineau@kernel.org>
Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
Link: https://patch.msgid.link/20260605-net-next-mptcp-add-addr6-port-ts-v2-7-758e7ca73f4d@kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
tools/testing/selftests/net/mptcp/mptcp_join.sh

index 70d5b26be4e0ccee94dcea417a8df6417aa93919..6aba8f97275aa8381e206beb54eba6aa08b4e2cc 100755 (executable)
@@ -3214,6 +3214,17 @@ add_addr_ports_tests()
                chk_add_nr 1 1 1
        fi
 
+       # signal address v6 with port
+       if reset "signal address v6 with port" &&
+          continue_if mptcp_lib_has_file '/proc/sys/net/mptcp/add_addr_v6_port_drop_ts'; then
+               pm_nl_set_limits $ns1 0 1
+               pm_nl_set_limits $ns2 1 1
+               pm_nl_add_endpoint $ns1 dead:beef:2::1 flags signal port 10100
+               run_tests $ns1 $ns2 dead:beef:1::1
+               chk_join_nr 1 1 1
+               chk_add_nr 1 1 1
+       fi
+
        # subflow and signal with port
        if reset "subflow and signal with port"; then
                pm_nl_add_endpoint $ns1 10.0.2.1 flags signal port 10100