]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
selftests: openvswitch: fix tcpdump execution
authorAdrian Moreno <amorenoz@redhat.com>
Tue, 17 Dec 2024 21:16:51 +0000 (22:16 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 27 Dec 2024 13:02:05 +0000 (14:02 +0100)
commitcb82774ee7213adff2a7912b5e805038208f0696
tree74d40d7c3182f962586bedf97abbd8eadb50de31
parent8fe8bffbb997db50f9f3242e9db42be5f17c5ffe
selftests: openvswitch: fix tcpdump execution

[ Upstream commit a17975992cc11588767175247ccaae1213a8b582 ]

Fix the way tcpdump is executed by:
- Using the right variable for the namespace. Currently the use of the
  empty "ns" makes the command fail.
- Waiting until it starts to capture to ensure the interesting traffic
  is caught on slow systems.
- Using line-buffered output to ensure logs are available when the test
  is paused with "-p". Otherwise the last chunk of data might only be
  written when tcpdump is killed.

Fixes: 74cc26f416b9 ("selftests: openvswitch: add interface support")
Signed-off-by: Adrian Moreno <amorenoz@redhat.com>
Acked-by: Eelco Chaudron <echaudro@redhat.com>
Link: https://patch.msgid.link/20241217211652.483016-1-amorenoz@redhat.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
tools/testing/selftests/net/openvswitch/openvswitch.sh