linux-stable/tools/testing
Petr Machata 68d9cea594 selftests: forwarding: lib: Parameterize NUM_NETIFS in two functions
setup_wait() and tc_offload_check() both assume that all NUM_NETIFS
interfaces are relevant for a given test. However, the scale test script
acts as an umbrella for a number of sub-tests, some of which may not
require all the interfaces.

Thus it's suboptimal for tc_offload_check() to query all the interfaces.
In case of setup_wait() it's incorrect, because the sub-test in question
of course doesn't configure any interfaces beyond what it needs, and
setup_wait() then ends up waiting indefinitely for the extraneous
interfaces to come up.

For that reason, give setup_wait() and tc_offload_check() an optional
parameter with a number of interfaces to probe. Fall back to global
NUM_NETIFS if the parameter is not given.

Signed-off-by: Petr Machata <petrm@mellanox.com>
Reviewed-by: Yuval Mintz <yuvalm@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2018-06-30 22:06:15 +09:00
..
fault-injection License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
ktest These commits have either been sitting in my INBOX or have been 2018-04-11 16:42:27 -07:00
nvdimm x86, nfit_test: Add unit test for memcpy_mcsafe() 2018-05-22 23:18:31 -07:00
radix-tree idr: fix invalid ptr dereference on item delete 2018-05-25 18:12:10 -07:00
scatterlist tools/testing/scatterlist: Test new __sg_alloc_table_from_pages 2017-09-07 10:54:40 +01:00
selftests selftests: forwarding: lib: Parameterize NUM_NETIFS in two functions 2018-06-30 22:06:15 +09:00
vsock VSOCK: add tools/testing/vsock/vsock_diag_test 2017-10-05 18:44:17 -07:00