wifi: mt76: only consume the WO drop bit on WED v2 devices

The RX path is handled by the WO MCU only on WED v2 hardware. On WED
v3 the same buf1 bit does not carry drop information, so evaluating it
there causes spurious RX drops.

Fixes: e4d2b8bcac11 ("wifi: mt76: drop the incorrect scatter and gather frame")
Signed-off-by: Felix Fietkau <[email protected]>
This commit is contained in:
Felix Fietkau
2026-07-24 14:45:39 +02:00
parent 1ece37f8a9
commit 0e12344405
+6 -1
View File
@@ -547,8 +547,13 @@ mt76_dma_get_buf(struct mt76_dev *dev, struct mt76_queue *q, int idx,
t->ptr = NULL; t->ptr = NULL;
mt76_put_rxwi(dev, t); mt76_put_rxwi(dev, t);
if (drop) #ifdef CONFIG_NET_MEDIATEK_SOC_WED
/* the WO MCU owns the RX path only on WED v2, on newer
* versions this buf1 bit carries no drop information
*/
if (drop && dev->mmio.wed.version == 2)
*drop |= !!(buf1 & MT_DMA_CTL_WO_DROP); *drop |= !!(buf1 & MT_DMA_CTL_WO_DROP);
#endif
} else { } else {
dma_sync_single_for_cpu(dev->dma_dev, e->dma_addr[0], dma_sync_single_for_cpu(dev->dma_dev, e->dma_addr[0],
SKB_WITH_OVERHEAD(q->buf_size), SKB_WITH_OVERHEAD(q->buf_size),