diff options
author | Michal Kazior <michal.kazior@tieto.com> | 2013-07-31 10:55:15 +0200 |
---|---|---|
committer | Kalle Valo <kvalo@qca.qualcomm.com> | 2013-08-02 09:37:29 +0300 |
commit | 591ecdb8f276925251bb5f5fad7eb064979ecee1 (patch) | |
tree | 5a1f33c118683c8bf3501e313563ce3808f9ef22 | |
parent | 0dbd09e6284dc7c3de1470e2f1a3c83e0a0fc591 (diff) | |
download | op-kernel-dev-591ecdb8f276925251bb5f5fad7eb064979ecee1.zip op-kernel-dev-591ecdb8f276925251bb5f5fad7eb064979ecee1.tar.gz |
ath10k: fix failpath in MSI-X setup
pci_disable_msi() must be called if the initial
request_irq() fails.
Also add a warning message so it's possible to
distinguish request_irq() failure and
pci_enable_msi() failure.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
-rw-r--r-- | drivers/net/wireless/ath/ath10k/pci.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/net/wireless/ath/ath10k/pci.c b/drivers/net/wireless/ath/ath10k/pci.c index c71b488..d95439b 100644 --- a/drivers/net/wireless/ath/ath10k/pci.c +++ b/drivers/net/wireless/ath/ath10k/pci.c @@ -1990,8 +1990,13 @@ static int ath10k_pci_start_intr_msix(struct ath10k *ar, int num) ret = request_irq(ar_pci->pdev->irq + MSI_ASSIGN_FW, ath10k_pci_msi_fw_handler, IRQF_SHARED, "ath10k_pci", ar); - if (ret) + if (ret) { + ath10k_warn("request_irq(%d) failed %d\n", + ar_pci->pdev->irq + MSI_ASSIGN_FW, ret); + + pci_disable_msi(ar_pci->pdev); return ret; + } for (i = MSI_ASSIGN_CE_INITIAL; i <= MSI_ASSIGN_CE_MAX; i++) { ret = request_irq(ar_pci->pdev->irq + i, |