aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/intel/e1000e/netdev.c
diff options
context:
space:
mode:
authorDavid Ertman <david.m.ertman@intel.com>2014-07-11 02:21:23 -0400
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>2014-07-26 00:08:12 -0400
commit2116bc25e8aefd76503dfa2fc328eb8da684bb38 (patch)
treee9f2c7b9069d3a845834d61ef41e068e7c842afa /drivers/net/ethernet/intel/e1000e/netdev.c
parentb4c1e6bf1c8522a6c6c8f29226a1e2cf126431df (diff)
e1000e: Fix EEE in S5 w/ Runtime PM enabled
The process of shutting down the system causes a call to the close PM callback. The reset in close causes a loss of link, and the resultant LSC interrupt causes the Runtime PM idle callback to be called. The check for link (while link is down) in the idle callback is wiping the information about the EEE ability of the link partner. The information is still gone when the PHY is powered back up in the shutdown flow. This causes EEE in S5 to fail when Runtime PM is active. Save the link partner's EEE ability in the idle callback so that a Runtime PM event will not cause a loss of this information. Signed-off-by: Dave Ertman <david.m.ertman@intel.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Diffstat (limited to 'drivers/net/ethernet/intel/e1000e/netdev.c')
-rw-r--r--drivers/net/ethernet/intel/e1000e/netdev.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/net/ethernet/intel/e1000e/netdev.c b/drivers/net/ethernet/intel/e1000e/netdev.c
index fe3e42a6c8e9..1ce0d743029c 100644
--- a/drivers/net/ethernet/intel/e1000e/netdev.c
+++ b/drivers/net/ethernet/intel/e1000e/netdev.c
@@ -6357,9 +6357,14 @@ static int e1000e_pm_runtime_idle(struct device *dev)
6357 struct pci_dev *pdev = to_pci_dev(dev); 6357 struct pci_dev *pdev = to_pci_dev(dev);
6358 struct net_device *netdev = pci_get_drvdata(pdev); 6358 struct net_device *netdev = pci_get_drvdata(pdev);
6359 struct e1000_adapter *adapter = netdev_priv(netdev); 6359 struct e1000_adapter *adapter = netdev_priv(netdev);
6360 u16 eee_lp;
6360 6361
6361 if (!e1000e_has_link(adapter)) 6362 eee_lp = adapter->hw.dev_spec.ich8lan.eee_lp_ability;
6363
6364 if (!e1000e_has_link(adapter)) {
6365 adapter->hw.dev_spec.ich8lan.eee_lp_ability = eee_lp;
6362 pm_schedule_suspend(dev, 5 * MSEC_PER_SEC); 6366 pm_schedule_suspend(dev, 5 * MSEC_PER_SEC);
6367 }
6363 6368
6364 return -EBUSY; 6369 return -EBUSY;
6365} 6370}