diff options
author | Todd Fujinaka <todd.fujinaka@intel.com> | 2018-10-10 14:10:10 -0400 |
---|---|---|
committer | Jeff Kirsher <jeffrey.t.kirsher@intel.com> | 2018-11-07 12:47:01 -0500 |
commit | 540a152da762a2360e0dac18e2eafff2775c4670 (patch) | |
tree | fb8f02b990680b15ae381da6e2f01443d3a5a94d | |
parent | a9e510589d7017ee4e82800d0a1d78a694772787 (diff) |
i40e/ixgbe/igb: fail on new WoL flag setting WAKE_MAGICSECURE
There's a new flag for setting WoL filters that is only
enabled on one manufacturer's NICs, and it's not ours. Fail
with EOPNOTSUPP.
Signed-off-by: Todd Fujinaka <todd.fujinaka@intel.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
-rw-r--r-- | drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 3 | ||||
-rw-r--r-- | drivers/net/ethernet/intel/igb/igb_ethtool.c | 2 | ||||
-rw-r--r-- | drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c | 3 |
3 files changed, 5 insertions, 3 deletions
diff --git a/drivers/net/ethernet/intel/i40e/i40e_ethtool.c b/drivers/net/ethernet/intel/i40e/i40e_ethtool.c index 9f8464f80783..9c1211ad2c6b 100644 --- a/drivers/net/ethernet/intel/i40e/i40e_ethtool.c +++ b/drivers/net/ethernet/intel/i40e/i40e_ethtool.c | |||
@@ -2377,7 +2377,8 @@ static int i40e_set_wol(struct net_device *netdev, struct ethtool_wolinfo *wol) | |||
2377 | return -EOPNOTSUPP; | 2377 | return -EOPNOTSUPP; |
2378 | 2378 | ||
2379 | /* only magic packet is supported */ | 2379 | /* only magic packet is supported */ |
2380 | if (wol->wolopts && (wol->wolopts != WAKE_MAGIC)) | 2380 | if (wol->wolopts && (wol->wolopts != WAKE_MAGIC) |
2381 | | (wol->wolopts != WAKE_FILTER)) | ||
2381 | return -EOPNOTSUPP; | 2382 | return -EOPNOTSUPP; |
2382 | 2383 | ||
2383 | /* is this a new value? */ | 2384 | /* is this a new value? */ |
diff --git a/drivers/net/ethernet/intel/igb/igb_ethtool.c b/drivers/net/ethernet/intel/igb/igb_ethtool.c index 5acf3b743876..c57671068245 100644 --- a/drivers/net/ethernet/intel/igb/igb_ethtool.c +++ b/drivers/net/ethernet/intel/igb/igb_ethtool.c | |||
@@ -2113,7 +2113,7 @@ static int igb_set_wol(struct net_device *netdev, struct ethtool_wolinfo *wol) | |||
2113 | { | 2113 | { |
2114 | struct igb_adapter *adapter = netdev_priv(netdev); | 2114 | struct igb_adapter *adapter = netdev_priv(netdev); |
2115 | 2115 | ||
2116 | if (wol->wolopts & (WAKE_ARP | WAKE_MAGICSECURE)) | 2116 | if (wol->wolopts & (WAKE_ARP | WAKE_MAGICSECURE | WAKE_FILTER)) |
2117 | return -EOPNOTSUPP; | 2117 | return -EOPNOTSUPP; |
2118 | 2118 | ||
2119 | if (!(adapter->flags & IGB_FLAG_WOL_SUPPORTED)) | 2119 | if (!(adapter->flags & IGB_FLAG_WOL_SUPPORTED)) |
diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c index 732b1e6ecc43..acba067cc15a 100644 --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c | |||
@@ -2206,7 +2206,8 @@ static int ixgbe_set_wol(struct net_device *netdev, struct ethtool_wolinfo *wol) | |||
2206 | { | 2206 | { |
2207 | struct ixgbe_adapter *adapter = netdev_priv(netdev); | 2207 | struct ixgbe_adapter *adapter = netdev_priv(netdev); |
2208 | 2208 | ||
2209 | if (wol->wolopts & (WAKE_PHY | WAKE_ARP | WAKE_MAGICSECURE)) | 2209 | if (wol->wolopts & (WAKE_PHY | WAKE_ARP | WAKE_MAGICSECURE | |
2210 | WAKE_FILTER)) | ||
2210 | return -EOPNOTSUPP; | 2211 | return -EOPNOTSUPP; |
2211 | 2212 | ||
2212 | if (ixgbe_wol_exclusion(adapter, wol)) | 2213 | if (ixgbe_wol_exclusion(adapter, wol)) |