Skip to contentSkip to conversation

ixgbe: fix crash when injecting AER after failed reset

PATCH New Emil Tantilov 2 participants 2 messages Sep 29, 2017 – Oct 4, 2017

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

PATCH 1/1 ixgbe: fix crash when injecting AER after failed reset

In case where AER recovery fails the device is left in a down state. Consecutive AER error injection can lead to a double IRQ free.

---
 drivers/net/ethernet/intel/ixgbe/ixgbe_main.c |    3 +++
 1 file changed, 3 insertions(+)
drivers/net/ethernet/intel/ixgbe/ixgbe_main.c +3 -0
index f854ce2..0c3f9c8 100644
@@ -10890,6 +10890,9 @@ static pci_ers_result_t ixgbe_io_error_detected(struct pci_dev *pdev,
 	if (!test_bit(__IXGBE_SERVICE_INITED, &adapter->state))
 		return PCI_ERS_RESULT_DISCONNECT;
 
+	if (!netif_device_present(netdev))
+		return PCI_ERS_RESULT_DISCONNECT;
+
 	rtnl_lock();
 	netif_device_detach(netdev);
 
#1 lore raw

PATCH 1/1 ixgbe: fix crash when injecting AER after failed reset

Quoted 8 lines

-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at osuosl.org] On Behalf Of Emil Tantilov
Sent: Friday, September 29, 2017 10:56 AM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [PATCH] ixgbe: fix crash when injecting AER after failed reset

Quoted 7 lines

In case where AER recovery fails the device is left in a down state. Consecutive AER error injection can lead to a double IRQ free.

---
 drivers/net/ethernet/intel/ixgbe/ixgbe_main.c |    3 +++
 1 file changed, 3 insertions(+)