ath10k: fix get invalid tx rate for Mesh metric
authorMiaoqing Pan <miaoqing@codeaurora.org>
Wed, 6 Nov 2019 18:04:37 +0000 (20:04 +0200)
committerKalle Valo <kvalo@codeaurora.org>
Fri, 8 Nov 2019 08:40:06 +0000 (10:40 +0200)
ath10k does not provide transmit rate info per MSDU
in tx completion, mark that as -1 so mac80211
will ignore the rates. This fixes mac80211 update Mesh
link metric with invalid transmit rate info.

Tested HW: QCA9984
Tested FW: 10.4-3.9.0.2-00035

Signed-off-by: Hou Bao Hou <houbao@codeaurora.org>
Signed-off-by: Anilkumar Kolli <akolli@codeaurora.org>
Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/ath/ath10k/txrx.c

index 4102df0169311411ef054287f81512317b32d6a1..39abf8b1290351617435dc2e50a44b233a68d29b 100644 (file)
@@ -95,6 +95,8 @@ int ath10k_txrx_tx_unref(struct ath10k_htt *htt,
 
        info = IEEE80211_SKB_CB(msdu);
        memset(&info->status, 0, sizeof(info->status));
+       info->status.rates[0].idx = -1;
+
        trace_ath10k_txrx_tx_unref(ar, tx_done->msdu_id);
 
        if (!(info->flags & IEEE80211_TX_CTL_NO_ACK))