From eeb7fc7bc095546b21188e8e076a59bce73f9ca6 Mon Sep 17 00:00:00 2001 From: Somnath Kotur Date: Wed, 2 May 2012 03:41:01 +0000 Subject: [PATCH] be2net: Fix EEH error reset before a flash dump completes An EEH error can cause the FW to trigger a flash debug dump. Resetting the card while flash dump is in progress can cause it not to recover. Wait for it to finish before letting EEH flow to reset the card. Signed-off-by: Sathya Perla Signed-off-by: Somnath Kotur Signed-off-by: David S. Miller --- drivers/net/ethernet/emulex/benet/be_main.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/net/ethernet/emulex/benet/be_main.c b/drivers/net/ethernet/emulex/benet/be_main.c index b7bc905a93fb..6d5d30be0481 100644 --- a/drivers/net/ethernet/emulex/benet/be_main.c +++ b/drivers/net/ethernet/emulex/benet/be_main.c @@ -3821,6 +3821,11 @@ static pci_ers_result_t be_eeh_err_detected(struct pci_dev *pdev, pci_disable_device(pdev); + /* The error could cause the FW to trigger a flash debug dump. + * Resetting the card while flash dump is in progress + * can cause it not to recover; wait for it to finish + */ + ssleep(30); return PCI_ERS_RESULT_NEED_RESET; }