]> git.baikalelectronics.ru Git - kernel.git/commit
selftests: forwarding: mirror_lib: Wait for tardy mirrored packets
authorPetr Machata <petrm@mellanox.com>
Thu, 31 Jan 2019 22:35:17 +0000 (22:35 +0000)
committerDavid S. Miller <davem@davemloft.net>
Fri, 1 Feb 2019 23:26:36 +0000 (15:26 -0800)
commit8438047e26dad7d61618527e46069c8150b44da9
tree6e1ab4b496403fb1e33a23736a24db9498b71ba8
parentd67924ee4557e12672da5313923496638664791e
selftests: forwarding: mirror_lib: Wait for tardy mirrored packets

When running in an environment with poor performance (such as a
simulator), processing mirrored packets can take a while. Evaluating the
condition too soon leads to spurious "seen 9, expected 10" failures as
the last packet doesn't have enough time to get mirrored and the mirror
to arrive and bump the observed counters.

Wait for one ping interval before evaluating the test.

Signed-off-by: Petr Machata <petrm@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
tools/testing/selftests/net/forwarding/mirror_lib.sh