Skip to content

Commit

Permalink
selftests: forwarding: Add MAC get helper
Browse files Browse the repository at this point in the history
Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Jiri Pirko authored and David S. Miller committed Feb 28, 2018
1 parent 2f19f21 commit 4e4272d
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions tools/testing/selftests/net/forwarding/lib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -270,6 +270,13 @@ link_stats_tx_packets_get()
ip -j -s link show dev $if_name | jq '.[]["stats64"]["tx"]["packets"]'
}

mac_get()
{
local if_name=$1

ip -j link show dev $if_name | jq -r '.[]["address"]'
}

bridge_ageing_time_get()
{
local bridge=$1
Expand Down

0 comments on commit 4e4272d

Please sign in to comment.