]> git.baikalelectronics.ru Git - kernel.git/commit
selftests: fib_tests: sleep after changing carrier. again.
authorThadeu Lima de Souza Cascardo <cascardo@canonical.com>
Fri, 22 Feb 2019 10:27:41 +0000 (07:27 -0300)
committerDavid S. Miller <davem@davemloft.net>
Sun, 24 Feb 2019 02:34:20 +0000 (18:34 -0800)
commit51f96cc98d0e259e8882738b1ec78b3bb75f46b8
treee10d30ee65265f7177c40167c233d01067fbd88a
parentdcad78411c063868c025f8e3791a30add6de86d4
selftests: fib_tests: sleep after changing carrier. again.

Just like commit 41b164b2a35a ("selftests: fib_tests: sleep after
changing carrier"), wait one second to allow linkwatch to propagate the
carrier change to the stack.

There are two sets of carrier tests. The first slept after the carrier
was set to off, and when the second set ran, it was likely that the
linkwatch would be able to run again without much delay, reducing the
likelihood of a race. However, if you run 'fib_tests.sh -t carrier' on a
loop, you will quickly notice the failures.

Sleeping on the second set of tests make the failures go away.

Cc: David Ahern <dsahern@gmail.com>
Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@canonical.com>
Reviewed-by: David Ahern <dsahern@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
tools/testing/selftests/net/fib_tests.sh