diff options
| author | Wei Yongjun <weiyongjun1@huawei.com> | 2016-09-16 13:05:35 +0000 |
|---|---|---|
| committer | Govind Singh <govinds@codeaurora.org> | 2017-01-06 15:59:10 +0530 |
| commit | f3adb5a35638580c853dccf167338c983dfc100e (patch) | |
| tree | fc83eb3de3a0f77e2d7647fa0d030fe74ea535e2 | |
| parent | 0d1f3862c2a88a05e9ca21c60e822ec7d0125990 (diff) | |
ath10k: fix error return code in ahb
Fix to return a negative error code from the error handling case
instead of 0, as done elsewhere in function ath10k_ahb_probe() or
ath10k_ahb_resource_init().
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
| -rw-r--r-- | drivers/net/wireless/ath/ath10k/ahb.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath10k/ahb.c b/drivers/net/wireless/ath/ath10k/ahb.c index fe38b459544d..766c63bf05c4 100644 --- a/drivers/net/wireless/ath/ath10k/ahb.c +++ b/drivers/net/wireless/ath/ath10k/ahb.c @@ -509,6 +509,7 @@ static int ath10k_ahb_resource_init(struct ath10k *ar) ar_ahb->irq = platform_get_irq_byname(pdev, "legacy"); if (ar_ahb->irq < 0) { ath10k_err(ar, "failed to get irq number: %d\n", ar_ahb->irq); + ret = ar_ahb->irq; goto err_clock_deinit; } @@ -787,6 +788,7 @@ static int ath10k_ahb_probe(struct platform_device *pdev) chip_id = ath10k_ahb_soc_read32(ar, SOC_CHIP_ID_ADDRESS); if (chip_id == 0xffffffff) { ath10k_err(ar, "failed to get chip id\n"); + ret = -ENODEV; goto err_halt_device; } |
