]> www.infradead.org Git - users/jedix/linux-maple.git/commit
tg3: Fix stats while interface is down
authorMatt Carlson <mcarlson@broadcom.com>
Mon, 13 Feb 2012 15:20:09 +0000 (15:20 +0000)
committerJoe Jin <joe.jin@oracle.com>
Tue, 28 Aug 2012 07:21:32 +0000 (15:21 +0800)
commite442f3310001a77901ad3318c64712fec172d856
tree246961ada52c0b674b9c0d7df409c379c28e8cd2
parent9ac4937c8ceb2122e26a3e6df132ed926c39a27d
tg3: Fix stats while interface is down

If the tg3 interface is down, the driver will return ethtool stats
uninitialized.  This patch zeroes out the destination stat buffer in
such a case.

(cherry picked from commit b546e46f5c9f19a921d6f62db80f2e9371bc0558)
Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Joe Jin <joe.jin@oracle.com>
drivers/net/tg3.c