diff options
author | Bing Zhao <bzhao@marvell.com> | 2009-11-10 02:04:13 (GMT) |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-11-10 21:21:16 (GMT) |
commit | c3b866ad7ef9a74fc2e0d7f0c5520ad09c8536f3 (patch) | |
tree | d071658582974410c2726e2e6df66885cacd8f3f /drivers/net/wireless/libertas/ethtool.c | |
parent | 866d4700150656b928f366c395bab9ab0e1a06a3 (diff) | |
download | linux-fsl-qoriq-c3b866ad7ef9a74fc2e0d7f0c5520ad09c8536f3.tar.xz |
Libertas: fix issues while configuring host sleep using ethtool wol
Configuration of wake-on-lan for unicast, multicast, broadcast, physical
activity was not working. Kernel panic issue was there when user tries to
disable WOL. Fixed them.
Signed-off-by: Amitkumar Karwar <akarwar@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/libertas/ethtool.c')
-rw-r--r-- | drivers/net/wireless/libertas/ethtool.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/net/wireless/libertas/ethtool.c b/drivers/net/wireless/libertas/ethtool.c index 6efa388..53d56ab 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, struct lbs_private *priv = dev->ml_priv; uint32_t criteria = 0; - if (priv->wol_criteria == 0xffffffff && wol->wolopts) - return -EOPNOTSUPP; - if (wol->wolopts & ~(WAKE_UCAST|WAKE_MCAST|WAKE_BCAST|WAKE_PHY)) return -EOPNOTSUPP; @@ -183,6 +180,8 @@ static int lbs_ethtool_set_wol(struct net_device *dev, criteria |= EHS_WAKE_ON_BROADCAST_DATA; if (wol->wolopts & WAKE_PHY) criteria |= EHS_WAKE_ON_MAC_EVENT; + if (wol->wolopts == 0) + criteria |= EHS_REMOVE_WAKEUP; return lbs_host_sleep_cfg(priv, criteria, (struct wol_config *)NULL); } |