aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/libertas/ethtool.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless/libertas/ethtool.c')
-rw-r--r--drivers/net/wireless/libertas/ethtool.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/net/wireless/libertas/ethtool.c b/drivers/net/wireless/libertas/ethtool.c
index 6efa3882d0a6..53d56ab83c03 100644
--- a/drivers/net/wireless/libertas/ethtool.c
+++ b/drivers/net/wireless/libertas/ethtool.c
@@ -169,9 +169,6 @@ static int lbs_ethtool_set_wol(struct net_device *dev,
169 struct lbs_private *priv = dev->ml_priv; 169 struct lbs_private *priv = dev->ml_priv;
170 uint32_t criteria = 0; 170 uint32_t criteria = 0;
171 171
172 if (priv->wol_criteria == 0xffffffff && wol->wolopts)
173 return -EOPNOTSUPP;
174
175 if (wol->wolopts & ~(WAKE_UCAST|WAKE_MCAST|WAKE_BCAST|WAKE_PHY)) 172 if (wol->wolopts & ~(WAKE_UCAST|WAKE_MCAST|WAKE_BCAST|WAKE_PHY))
176 return -EOPNOTSUPP; 173 return -EOPNOTSUPP;
177 174
@@ -183,6 +180,8 @@ static int lbs_ethtool_set_wol(struct net_device *dev,
183 criteria |= EHS_WAKE_ON_BROADCAST_DATA; 180 criteria |= EHS_WAKE_ON_BROADCAST_DATA;
184 if (wol->wolopts & WAKE_PHY) 181 if (wol->wolopts & WAKE_PHY)
185 criteria |= EHS_WAKE_ON_MAC_EVENT; 182 criteria |= EHS_WAKE_ON_MAC_EVENT;
183 if (wol->wolopts == 0)
184 criteria |= EHS_REMOVE_WAKEUP;
186 185
187 return lbs_host_sleep_cfg(priv, criteria, (struct wol_config *)NULL); 186 return lbs_host_sleep_cfg(priv, criteria, (struct wol_config *)NULL);
188} 187}