diff options
author | Nick Nunley <nicholasx.d.nunley@intel.com> | 2010-02-03 15:49:48 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-02-04 04:39:57 +0100 |
commit | dbb5aaebc44ce7f64b12904c58fbc1dd487982a7 (patch) | |
tree | 1e12e8b4bb53365666cc5e9763989b8c6535069b /drivers/net/e1000 | |
parent | e1000: Report link status in ethtool when interface is down (diff) | |
download | linux-dbb5aaebc44ce7f64b12904c58fbc1dd487982a7.tar.xz linux-dbb5aaebc44ce7f64b12904c58fbc1dd487982a7.zip |
e1000: call pci_save_state after pci_restore_state
This patch adds a call to pci_save_state() immediately after
the call to pci_restore_state(). Due to a change in the behavior
of pci_restore_state() it is necessary to call pci_save_state()
to keep the state_saved flag. This patch is based on a similar
patch for ixgbe.
Signed-off-by: Nicholas Nunley <nicholasx.d.nunley@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/e1000')
-rw-r--r-- | drivers/net/e1000/e1000_main.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/net/e1000/e1000_main.c b/drivers/net/e1000/e1000_main.c index 4ff50d6fe5e4..3b14dd718ab4 100644 --- a/drivers/net/e1000/e1000_main.c +++ b/drivers/net/e1000/e1000_main.c @@ -847,6 +847,9 @@ static int __devinit e1000_probe(struct pci_dev *pdev, goto err_pci_reg; pci_set_master(pdev); + err = pci_save_state(pdev); + if (err) + goto err_alloc_etherdev; err = -ENOMEM; netdev = alloc_etherdev(sizeof(struct e1000_adapter)); @@ -4596,6 +4599,7 @@ static int e1000_resume(struct pci_dev *pdev) pci_set_power_state(pdev, PCI_D0); pci_restore_state(pdev); + pci_save_state(pdev); if (adapter->need_ioport) err = pci_enable_device(pdev); |