qed: Fix VF removal sequence
authorMintz, Yuval <Yuval.Mintz@cavium.com>
Tue, 9 May 2017 12:07:48 +0000 (15:07 +0300)
committerDavid S. Miller <davem@davemloft.net>
Tue, 9 May 2017 15:24:22 +0000 (11:24 -0400)
After previos changes in HW-stop scheme, VFs stopped sending CLOSE
messages to their PFs when they unload.

Fixes: 1226337ad98f ("qed: Correct HW stop flow")
Signed-off-by: Yuval Mintz <Yuval.Mintz@cavium.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/qlogic/qed/qed_main.c

index b7ad36b91e12cb71bf6658ec8e568cc61472850f..0cbbd59e34a2e7b32e3f271b559af8471dfa07b9 100644 (file)
@@ -1093,10 +1093,12 @@ static int qed_slowpath_stop(struct qed_dev *cdev)
                qed_free_stream_mem(cdev);
                if (IS_QED_ETH_IF(cdev))
                        qed_sriov_disable(cdev, true);
+       }
+
+       qed_nic_stop(cdev);
 
-               qed_nic_stop(cdev);
+       if (IS_PF(cdev))
                qed_slowpath_irq_free(cdev);
-       }
 
        qed_disable_msix(cdev);