aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/net/e1000e/ethtool.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/net/e1000e/ethtool.c b/drivers/net/e1000e/ethtool.c
index c430dc8b70a3..3af5ee4a4cc8 100644
--- a/drivers/net/e1000e/ethtool.c
+++ b/drivers/net/e1000e/ethtool.c
@@ -1777,12 +1777,11 @@ static int e1000_set_wol(struct net_device *netdev,
1777{ 1777{
1778 struct e1000_adapter *adapter = netdev_priv(netdev); 1778 struct e1000_adapter *adapter = netdev_priv(netdev);
1779 1779
1780 if (wol->wolopts & WAKE_MAGICSECURE)
1781 return -EOPNOTSUPP;
1782
1783 if (!(adapter->flags & FLAG_HAS_WOL) || 1780 if (!(adapter->flags & FLAG_HAS_WOL) ||
1784 !device_can_wakeup(&adapter->pdev->dev)) 1781 !device_can_wakeup(&adapter->pdev->dev) ||
1785 return wol->wolopts ? -EOPNOTSUPP : 0; 1782 (wol->wolopts & ~(WAKE_UCAST | WAKE_MCAST | WAKE_BCAST |
1783 WAKE_MAGIC | WAKE_PHY | WAKE_ARP)))
1784 return -EOPNOTSUPP;
1786 1785
1787 /* these settings will always override what we currently have */ 1786 /* these settings will always override what we currently have */
1788 adapter->wol = 0; 1787 adapter->wol = 0;