diff options
author | Alexander Duyck <alexander.h.duyck@intel.com> | 2009-12-23 08:21:46 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-12-23 23:47:51 -0500 |
commit | 58b8b042509f53955ba660a4245e221c5405f124 (patch) | |
tree | d5223270808511fb8bf7a478f87407114cd6a638 /drivers/net | |
parent | d405ea3ef2499eb46834418a643973c884ff7f30 (diff) |
igb: check both function bits in status register in wol exception
The ethtool code for enabling Wake on Lan was not correctly checking the
status register bits so as a result ports 0 and 2 were both being allowed
to set WOL to enabled even though it is only supported on the first port
for our adapters.
Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/igb/igb_ethtool.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/igb/igb_ethtool.c b/drivers/net/igb/igb_ethtool.c index ac9d5272650d..f771a6c08777 100644 --- a/drivers/net/igb/igb_ethtool.c +++ b/drivers/net/igb/igb_ethtool.c | |||
@@ -1795,7 +1795,7 @@ static int igb_wol_exclusion(struct igb_adapter *adapter, | |||
1795 | /* dual port cards only support WoL on port A from now on | 1795 | /* dual port cards only support WoL on port A from now on |
1796 | * unless it was enabled in the eeprom for port B | 1796 | * unless it was enabled in the eeprom for port B |
1797 | * so exclude FUNC_1 ports from having WoL enabled */ | 1797 | * so exclude FUNC_1 ports from having WoL enabled */ |
1798 | if (rd32(E1000_STATUS) & E1000_STATUS_FUNC_1 && | 1798 | if ((rd32(E1000_STATUS) & E1000_STATUS_FUNC_MASK) && |
1799 | !adapter->eeprom_wol) { | 1799 | !adapter->eeprom_wol) { |
1800 | wol->supported = 0; | 1800 | wol->supported = 0; |
1801 | break; | 1801 | break; |