@@ -1430,10 +1430,16 @@ mt7915_mac_add_txs_skb(struct mt7915_dev *dev, struct mt76_wcid *wcid, int pid,
* paired with TXS data. This is normal datapath.
*/
struct rate_info *rate = &wcid->rate;
- struct sk_buff *skb;
+ struct sk_buff *skb = NULL;
+ bool check_status;
- mt76_tx_status_lock(mdev, &list);
- skb = mt76_tx_status_skb_get(mdev, wcid, pid, &list);
+ check_status = ((pid >= MT_PACKET_ID_FIRST) ||
+ time_after(jiffies, mdev->next_status_jiffies));
+
+ if (check_status) {
+ mt76_tx_status_lock(mdev, &list);
+ skb = mt76_tx_status_skb_get(mdev, wcid, pid, &list);
+ }
memset(rate, 0, sizeof(*rate));
@@ -1447,7 +1453,8 @@ mt7915_mac_add_txs_skb(struct mt7915_dev *dev, struct mt76_wcid *wcid, int pid,
if (skb)
mt76_tx_status_skb_done(mdev, skb, &list, wcid);
- mt76_tx_status_unlock(mdev, &list);
+ if (check_status)
+ mt76_tx_status_unlock(mdev, &list);
}
static void mt7915_mac_add_txs(struct mt7915_dev *dev, void *data)
@@ -1469,7 +1476,7 @@ static void mt7915_mac_add_txs(struct mt7915_dev *dev, void *data)
txs = le32_to_cpu(txs_data[3]);
pid = FIELD_GET(MT_TXS3_PID, txs);
- if (pid < MT_PACKET_ID_FIRST)
+ if (pid < MT_PACKET_ID_NO_SKB)
return;
if (wcidx >= MT7915_WTBL_SIZE)