Browse Source

ixgbe: Restore hw_addr in LER recovery paths

The hw_addr needs to be restored in the pcie recovery path or
else the device will be perpetually removed. Also restore the
value in the resume path.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Signed-off-by: Aaron Brown <aaron.f.brown@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Mark Rustad 11 years ago
parent
commit
0391bbe3e4
1 changed files with 4 additions and 2 deletions
  1. 4 2
      drivers/net/ethernet/intel/ixgbe/ixgbe_main.c

+ 4 - 2
drivers/net/ethernet/intel/ixgbe/ixgbe_main.c

@@ -1,7 +1,7 @@
 /*******************************************************************************
 /*******************************************************************************
 
 
   Intel 10 Gigabit PCI Express Linux driver
   Intel 10 Gigabit PCI Express Linux driver
-  Copyright(c) 1999 - 2013 Intel Corporation.
+  Copyright(c) 1999 - 2014 Intel Corporation.
 
 
   This program is free software; you can redistribute it and/or modify it
   This program is free software; you can redistribute it and/or modify it
   under the terms and conditions of the GNU General Public License,
   under the terms and conditions of the GNU General Public License,
@@ -67,7 +67,7 @@ static char ixgbe_default_device_descr[] =
 #define DRV_VERSION "3.19.1-k"
 #define DRV_VERSION "3.19.1-k"
 const char ixgbe_driver_version[] = DRV_VERSION;
 const char ixgbe_driver_version[] = DRV_VERSION;
 static const char ixgbe_copyright[] =
 static const char ixgbe_copyright[] =
-				"Copyright (c) 1999-2013 Intel Corporation.";
+				"Copyright (c) 1999-2014 Intel Corporation.";
 
 
 static const struct ixgbe_info *ixgbe_info_tbl[] = {
 static const struct ixgbe_info *ixgbe_info_tbl[] = {
 	[board_82598] = &ixgbe_82598_info,
 	[board_82598] = &ixgbe_82598_info,
@@ -5508,6 +5508,7 @@ static int ixgbe_resume(struct pci_dev *pdev)
 	struct net_device *netdev = adapter->netdev;
 	struct net_device *netdev = adapter->netdev;
 	u32 err;
 	u32 err;
 
 
+	adapter->hw.hw_addr = adapter->io_addr;
 	pci_set_power_state(pdev, PCI_D0);
 	pci_set_power_state(pdev, PCI_D0);
 	pci_restore_state(pdev);
 	pci_restore_state(pdev);
 	/*
 	/*
@@ -8453,6 +8454,7 @@ static pci_ers_result_t ixgbe_io_slot_reset(struct pci_dev *pdev)
 		e_err(probe, "Cannot re-enable PCI device after reset.\n");
 		e_err(probe, "Cannot re-enable PCI device after reset.\n");
 		result = PCI_ERS_RESULT_DISCONNECT;
 		result = PCI_ERS_RESULT_DISCONNECT;
 	} else {
 	} else {
+		adapter->hw.hw_addr = adapter->io_addr;
 		pci_set_master(pdev);
 		pci_set_master(pdev);
 		pci_restore_state(pdev);
 		pci_restore_state(pdev);
 		pci_save_state(pdev);
 		pci_save_state(pdev);