Skip to contentSkip to conversation

atl1*: add device_set_wakeup_enable to atl1*_set_wol

PATCH In review Brandon Philips 2 participants 3 messages Jun 25, 2009

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 atl1*: add device_set_wakeup_enable to atl1*_set_wol

Tell PCI core that atl1* device can wakeup the system when WOL is enabled by calling device_set_wakeup_enable.

Joerg noted that his atl1e device WOL fine after enabling it with ethtool and changing /sys/class/net/eth0/device/power/wakeup to enabled Tested on atl1e: https://bugzilla.novell.com/show_bug.cgi?id=493214

Tested by: Joerg Reuter <[email protected]>

---
 drivers/net/atl1c/atl1c_ethtool.c |    2 ++
 drivers/net/atl1e/atl1e_ethtool.c |    2 ++
 2 files changed, 4 insertions(+)
drivers/net/atl1e/atl1e_ethtool.c +2 -0
Index: linux-2.6/drivers/net/atl1e/atl1e_ethtool.c
===================================================================
@@ -365,6 +365,8 @@ static int atl1e_set_wol(struct net_devi
 	if (wol->wolopts & WAKE_PHY)
 		adapter->wol |= AT_WUFC_LNKC;
 
+	device_set_wakeup_enable(&adapter->pdev->dev, adapter->wol);
+
 	return 0;
 }
 
drivers/net/atl1c/atl1c_ethtool.c +2 -0
Index: linux-2.6/drivers/net/atl1c/atl1c_ethtool.c
===================================================================
@@ -281,6 +281,8 @@ static int atl1c_set_wol(struct net_devi
 	if (wol->wolopts & WAKE_PHY)
 		adapter->wol |= AT_WUFC_LNKC;
 
+	device_set_wakeup_enable(&adapter->pdev->dev, adapter->wol);
+
 	return 0;
 }
 
#1 lore raw

BTW, Chris Snook's email address bounced. Can someone with a newer address update MAINTAINERS?

Quoted 41 lines · Brandon Philips

Tell PCI core that atl1* device can wakeup the system when WOL is enabled by calling device_set_wakeup_enable.

Joerg noted that his atl1e device WOL fine after enabling it with ethtool and changing /sys/class/net/eth0/device/power/wakeup to enabled Tested on atl1e: https://bugzilla.novell.com/show_bug.cgi?id=493214

Tested by: Joerg Reuter <[email protected]>

---
 drivers/net/atl1c/atl1c_ethtool.c |    2 ++
 drivers/net/atl1e/atl1e_ethtool.c |    2 ++
 2 files changed, 4 insertions(+)

Index: linux-2.6/drivers/net/atl1e/atl1e_ethtool.c
===================================================================

drivers/net/atl1e/atl1e_ethtool.c +2 -0
@@ -365,6 +365,8 @@ static int atl1e_set_wol(struct net_devi
 	if (wol->wolopts & WAKE_PHY)
 		adapter->wol |= AT_WUFC_LNKC;
 
+	device_set_wakeup_enable(&adapter->pdev->dev, adapter->wol);
+
 	return 0;
 }
 

Index: linux-2.6/drivers/net/atl1c/atl1c_ethtool.c
===================================================================

drivers/net/atl1c/atl1c_ethtool.c +2 -0
@@ -281,6 +281,8 @@ static int atl1c_set_wol(struct net_devi
 	if (wol->wolopts & WAKE_PHY)
 		adapter->wol |= AT_WUFC_LNKC;
 
+	device_set_wakeup_enable(&adapter->pdev->dev, adapter->wol);
+
 	return 0;
 }
 
#2 lore raw
Quoted 2 lines · Brandon Philips

BTW, Chris Snook's email address bounced. Can someone with a newer address update MAINTAINERS?

Sorry about that. I'll send a patch momentarily.

-- Chris