aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ath/ath10k/wmi.c
diff options
context:
space:
mode:
authorMichal Kazior <michal.kazior@tieto.com>2015-08-19 13:10:43 +0200
committerKalle Valo <kvalo@qca.qualcomm.com>2015-08-26 11:04:44 +0300
commit5e55e3cbd1042cffa6249f22c10585e63f8a29bf (patch)
tree625a8b7976365f47aee86ea36e353eccb1b9f85b /drivers/net/wireless/ath/ath10k/wmi.c
parentath10k: add missing mutex unlock on failpath (diff)
downloadlinux-dev-5e55e3cbd1042cffa6249f22c10585e63f8a29bf.tar.xz
linux-dev-5e55e3cbd1042cffa6249f22c10585e63f8a29bf.zip
ath10k: fix dma_mapping_error() handling
The function returns 1 when DMA mapping fails. The driver would return bogus values and could possibly confuse itself if DMA failed. Fixes: 767d34fc67af ("ath10k: remove DMA mapping wrappers") Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Diffstat (limited to '')
-rw-r--r--drivers/net/wireless/ath/ath10k/wmi.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath10k/wmi.c b/drivers/net/wireless/ath/ath10k/wmi.c
index 42c0aba04fb2..6ac016dc28f8 100644
--- a/drivers/net/wireless/ath/ath10k/wmi.c
+++ b/drivers/net/wireless/ath/ath10k/wmi.c
@@ -3238,6 +3238,7 @@ void ath10k_wmi_event_host_swba(struct ath10k *ar, struct sk_buff *skb)
ath10k_warn(ar, "failed to map beacon: %d\n",
ret);
dev_kfree_skb_any(bcn);
+ ret = -EIO;
goto skip;
}