]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commit
selftests: mptcp: sockopt: use 'iptables-legacy' if available
authorMatthieu Baerts <matthieu.baerts@tessares.net>
Tue, 4 Jul 2023 20:44:36 +0000 (22:44 +0200)
committerDavid S. Miller <davem@davemloft.net>
Wed, 5 Jul 2023 09:51:14 +0000 (10:51 +0100)
commita5a5990c099dd354e05e89ee77cd2dbf6655d4a1
tree06acd7381b266eaf864dd11f3e273e3451a22485
parent221e4550454a822f9a11834e30694c7d1d65747c
selftests: mptcp: sockopt: use 'iptables-legacy' if available

IPTables commands using 'iptables-nft' fail on old kernels, at least
on v5.15 because it doesn't see the default IPTables chains:

  $ iptables -L
  iptables/1.8.2 Failed to initialize nft: Protocol not supported

As a first step before switching to NFTables, we can use iptables-legacy
if available.

Link: https://github.com/multipath-tcp/mptcp_net-next/issues/368
Fixes: dc65fe82fb07 ("selftests: mptcp: add packet mark test case")
Cc: stable@vger.kernel.org
Acked-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Matthieu Baerts <matthieu.baerts@tessares.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
tools/testing/selftests/net/mptcp/mptcp_sockopt.sh