summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/mediatek/mt76
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@nbd.name>2024-08-27 12:30:11 +0300
committerFelix Fietkau <nbd@nbd.name>2024-09-06 15:23:07 +0300
commitb13cd593ef2402e413e5c5c63e1b5e9ab5ed0e6e (patch)
tree34d254c91390e1950aec77cda650aca1515fec68 /drivers/net/wireless/mediatek/mt76
parent9e461f4a2329109571f4b10f9bcad28d07e6ebb3 (diff)
downloadlinux-b13cd593ef2402e413e5c5c63e1b5e9ab5ed0e6e.tar.xz
wifi: mt76: mt7915: avoid long MCU command timeouts during SER
Immediately abort MCU commands when firmware requests DMA restart. Link: https://patch.msgid.link/20240827093011.18621-24-nbd@nbd.name Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'drivers/net/wireless/mediatek/mt76')
-rw-r--r--drivers/net/wireless/mediatek/mt76/mt7915/mac.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/net/wireless/mediatek/mt76/mt7915/mac.c b/drivers/net/wireless/mediatek/mt76/mt7915/mac.c
index 54974ff72a5b..cf77ce0c8759 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7915/mac.c
+++ b/drivers/net/wireless/mediatek/mt76/mt7915/mac.c
@@ -1696,6 +1696,11 @@ void mt7915_reset(struct mt7915_dev *dev)
return;
}
+ if ((READ_ONCE(dev->recovery.state) & MT_MCU_CMD_STOP_DMA)) {
+ set_bit(MT76_MCU_RESET, &dev->mphy.state);
+ wake_up(&dev->mt76.mcu.wait);
+ }
+
queue_work(dev->mt76.wq, &dev->reset_work);
wake_up(&dev->reset_wait);
}