ath10k: clear tx status before submitting to mac80211
authorMichal Kazior <michal.kazior@tieto.com>
Thu, 14 Nov 2013 09:34:18 +0000 (10:34 +0100)
committerKalle Valo <kvalo@qca.qualcomm.com>
Fri, 15 Nov 2013 09:04:53 +0000 (11:04 +0200)
Garbage was reported in ieee80211_tx_info. This
led to a WARN_ON in cfg80211_calculate_bitrate().

This also fixes some random tx bitrate values
reported through `iw` command.

Reported-By: Kalle Valo <kvalo@qca.qualcomm.com>
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
drivers/net/wireless/ath/ath10k/txrx.c

index df279a31e189ddeb58aaf982d4780e4bce32ab08..d476b2cc9d781bebd0eaae792a6a05339cf94027 100644 (file)
@@ -75,6 +75,7 @@ void ath10k_txrx_tx_unref(struct ath10k_htt *htt,
        ath10k_report_offchan_tx(htt->ar, msdu);
 
        info = IEEE80211_SKB_CB(msdu);
+       memset(info, 0, sizeof(*info));
 
        if (tx_done->discard) {
                ieee80211_free_txskb(htt->ar->hw, msdu);