From f5b57ffab5f8945f3994f9a82df23e2614ffac32 Mon Sep 17 00:00:00 2001 From: Michael Lo Date: Mon, 12 Jan 2026 19:40:07 +0800 Subject: [PATCH] wifi: mt76: mt7925: Skip scan process during suspend. We are experiencing command timeouts because an upper layer triggers an unexpected scan while the system/device is in suspend. The upper layer should not initiate scans until the NIC has fully resumed. We want to prevent scans during suspend and avoid timeouts without harming power management or user experience. Signed-off-by: Michael Lo Link: https://patch.msgid.link/20260112114007.2115873-1-leon.yen@mediatek.com Signed-off-by: Felix Fietkau --- mt7925/main.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/mt7925/main.c b/mt7925/main.c index d368ca4e..afcc0fa4 100644 --- a/mt7925/main.c +++ b/mt7925/main.c @@ -1331,10 +1331,18 @@ void mt7925_mlo_pm_work(struct work_struct *work) void mt7925_scan_work(struct work_struct *work) { struct mt792x_phy *phy; + struct mt792x_dev *dev; + struct mt76_connac_pm *pm; phy = (struct mt792x_phy *)container_of(work, struct mt792x_phy, scan_work.work); + dev = phy->dev; + pm = &dev->pm; + + if (pm->suspended) + return; + while (true) { struct sk_buff *skb; struct tlv *tlv;