aboutsummaryrefslogtreecommitdiffstats
path: root/tools/testing/selftests/drivers/net/mlxsw/hw_stats_l3.sh
blob: 941ba4c485c97d5381b3ead70ae6ecfa6fc965ca (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#!/bin/bash
# SPDX-License-Identifier: GPL-2.0

lib_dir=$(dirname $0)/../../../net/forwarding

ALL_TESTS="
	l3_monitor_test
"
NUM_NETIFS=0
source $lib_dir/lib.sh

swp=$NETIF_NO_CABLE

cleanup()
{
	pre_cleanup
}

l3_monitor_test()
{
	hw_stats_monitor_test $swp l3		    \
		"ip addr add dev $swp 192.0.2.1/28" \
		"ip addr del dev $swp 192.0.2.1/28"
}

trap cleanup EXIT

setup_wait
tests_run

exit $EXIT_STATUS