]> git.baikalelectronics.ru Git - kernel.git/commit
tg3: allow ethtool -p to work for NICs in down state
authorJon Maxwell <jmaxwell37@gmail.com>
Tue, 2 Apr 2019 05:07:56 +0000 (16:07 +1100)
committerDavid S. Miller <davem@davemloft.net>
Tue, 2 Apr 2019 17:54:59 +0000 (10:54 -0700)
commit84a3f2718eb72988c3257929f01b3a58c83c8a65
tree0c397bf31519d39ca9137a53cd85251037f4ca6e
parentc44b1812e1d93f9c4617b595acddffe7e3375215
tg3: allow ethtool -p to work for NICs in down state

Make tg3 behave like other drivers and let "ethtool -p" identify the
NIC even when it's in the DOWN state. Before this patch it would get an
error as follows if the NIC was down:

# ip link set down dev em4
# ethtool -p em4
Cannot identify NIC: Resource temporarily unavailable

With this patch ethtool identify works regardless of whether the NIC is up
or down as it does for other drivers.

Signed-off-by: Jon Maxwell <jmaxwell37@gmail.com>
Acked-by: Michael Chan <michael.chan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/broadcom/tg3.c