selftests: forwarding: Convert until_counter_is() to take expression
authorPetr Machata <petrm@mellanox.com>
Mon, 2 Mar 2020 17:56:03 +0000 (19:56 +0200)
committerDavid S. Miller <davem@davemloft.net>
Wed, 4 Mar 2020 01:03:52 +0000 (17:03 -0800)
commit844f0556546900a658b241e5aea7b8dc7cb3ff72
tree4e9f78baefdcddff2a72d8ea522f86f0143fe87a
parent84ea1f8541721c1852bc95f4d50a603c661eabc6
selftests: forwarding: Convert until_counter_is() to take expression

until_counter_is() currently takes as an argument a number and the
condition holds when the current counter value is >= that number. Make the
function more generic by taking a partial expression instead of just the
number.

Convert the two existing users.

Signed-off-by: Petr Machata <petrm@mellanox.com>
Reviewed-by: Amit Cohen <amitc@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
tools/testing/selftests/drivers/net/mlxsw/sch_red_core.sh
tools/testing/selftests/net/forwarding/lib.sh