Sfoglia il codice sorgente

ath10k: prevent beacon memory leak

If DMA mapping of next beacon failed ath10k leaked
the beacon.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Michal Kazior 11 anni fa
parent
commit
ad3d2153bd
1 ha cambiato i file con 1 aggiunte e 0 eliminazioni
  1. 1 0
      drivers/net/wireless/ath/ath10k/wmi.c

+ 1 - 0
drivers/net/wireless/ath/ath10k/wmi.c

@@ -1441,6 +1441,7 @@ static void ath10k_wmi_event_host_swba(struct ath10k *ar, struct sk_buff *skb)
 					ATH10K_SKB_CB(bcn)->paddr);
 		if (ret) {
 			ath10k_warn("failed to map beacon: %d\n", ret);
+			dev_kfree_skb_any(bcn);
 			goto skip;
 		}