* [PATCH 27/34]bnx2x: Block nvram access when the device is inactive
@ 2009-01-14 16:44 Eilon Greenstein
2009-01-18 7:23 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Eilon Greenstein @ 2009-01-14 16:44 UTC (permalink / raw)
To: David Miller, netdev; +Cc: Paul Larson
Don't dump eeprom when bnx2x adapter is down. Running ethtool -e causes an eeh
without it when the device is down
Signed-off-by: Paul Larson <pl@linux.vnet.ibm.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
---
drivers/net/bnx2x_main.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/drivers/net/bnx2x_main.c b/drivers/net/bnx2x_main.c
index 678bc5d..0a18af0 100644
--- a/drivers/net/bnx2x_main.c
+++ b/drivers/net/bnx2x_main.c
@@ -8142,6 +8142,9 @@ static int bnx2x_get_eeprom(struct net_device *dev,
struct bnx2x *bp = netdev_priv(dev);
int rc;
+ if (!netif_running(dev))
+ return -EAGAIN;
+
DP(BNX2X_MSG_NVM, "ethtool_eeprom: cmd %d\n"
DP_LEVEL " magic 0x%x offset 0x%x (%d) len 0x%x (%d)\n",
eeprom->cmd, eeprom->magic, eeprom->offset, eeprom->offset,
--
1.5.4.3
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH 27/34]bnx2x: Block nvram access when the device is inactive
2009-01-14 16:44 [PATCH 27/34]bnx2x: Block nvram access when the device is inactive Eilon Greenstein
@ 2009-01-18 7:23 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2009-01-18 7:23 UTC (permalink / raw)
To: eilong; +Cc: netdev, pl
From: "Eilon Greenstein" <eilong@broadcom.com>
Date: Wed, 14 Jan 2009 18:44:07 +0200
> Don't dump eeprom when bnx2x adapter is down. Running ethtool -e causes an eeh
> without it when the device is down
>
> Signed-off-by: Paul Larson <pl@linux.vnet.ibm.com>
> Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Applied.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-01-18 7:23 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-14 16:44 [PATCH 27/34]bnx2x: Block nvram access when the device is inactive Eilon Greenstein
2009-01-18 7:23 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).