|
|
06c887 |
From 964125ac411b6b5cf34322887ee16d3e500c8d52 Mon Sep 17 00:00:00 2001
|
|
|
06c887 |
From: =?UTF-8?q?=C3=8D=C3=B1igo=20Huguet?= <ihuguet@redhat.com>
|
|
|
06c887 |
Date: Tue, 21 Dec 2021 14:23:22 +0100
|
|
|
06c887 |
Subject: [PATCH] mt76: connac: do not schedule mac_work if the device is not
|
|
|
06c887 |
running
|
|
|
06c887 |
MIME-Version: 1.0
|
|
|
06c887 |
Content-Type: text/plain; charset=UTF-8
|
|
|
06c887 |
Content-Transfer-Encoding: 8bit
|
|
|
06c887 |
|
|
|
06c887 |
Bugzilla: http://bugzilla.redhat.com/2041422
|
|
|
06c887 |
|
|
|
06c887 |
commit 6061fcf4820a2036189d0a6215f75a913f0fb5a1
|
|
|
06c887 |
Author: Lorenzo Bianconi <lorenzo@kernel.org>
|
|
|
06c887 |
Date: Fri Apr 23 16:27:11 2021 +0200
|
|
|
06c887 |
|
|
|
06c887 |
mt76: connac: do not schedule mac_work if the device is not running
|
|
|
06c887 |
|
|
|
06c887 |
Do not run ieee80211_queue_delayed_work for mac work if the worqueue is
|
|
|
06c887 |
not initialized yet
|
|
|
06c887 |
|
|
|
06c887 |
Fixes: b1bd7bb8121d ("mt76: connac: unschedule mac_work before going to sleep")
|
|
|
06c887 |
Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
|
|
|
06c887 |
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
|
|
|
06c887 |
Link: https://lore.kernel.org/r/5bfd36a75799c37b12fcb54d17e77fbc2c7a0558.1619187875.git.lorenzo@kernel.org
|
|
|
06c887 |
|
|
|
06c887 |
Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
|
|
|
06c887 |
---
|
|
|
06c887 |
drivers/net/wireless/mediatek/mt76/mt7615/mac.c | 5 +++--
|
|
|
06c887 |
drivers/net/wireless/mediatek/mt76/mt7921/mac.c | 5 +++--
|
|
|
06c887 |
2 files changed, 6 insertions(+), 4 deletions(-)
|
|
|
06c887 |
|
|
|
06c887 |
diff --git a/drivers/net/wireless/mediatek/mt76/mt7921/mac.c b/drivers/net/wireless/mediatek/mt76/mt7921/mac.c
|
|
|
06c887 |
index 214bd1859792..decf2d5f0ce3 100644
|
|
|
06c887 |
--- a/drivers/net/wireless/mediatek/mt76/mt7921/mac.c
|
|
|
06c887 |
+++ b/drivers/net/wireless/mediatek/mt76/mt7921/mac.c
|
|
|
06c887 |
@@ -1404,8 +1404,9 @@ void mt7921_pm_wake_work(struct work_struct *work)
|
|
|
06c887 |
napi_schedule(&dev->mt76.napi[i]);
|
|
|
06c887 |
mt76_connac_pm_dequeue_skbs(mphy, &dev->pm);
|
|
|
06c887 |
mt7921_tx_cleanup(dev);
|
|
|
06c887 |
- ieee80211_queue_delayed_work(mphy->hw, &mphy->mac_work,
|
|
|
06c887 |
- MT7921_WATCHDOG_TIME);
|
|
|
06c887 |
+ if (test_bit(MT76_STATE_RUNNING, &mphy->state))
|
|
|
06c887 |
+ ieee80211_queue_delayed_work(mphy->hw, &mphy->mac_work,
|
|
|
06c887 |
+ MT7921_WATCHDOG_TIME);
|
|
|
06c887 |
}
|
|
|
06c887 |
|
|
|
06c887 |
ieee80211_wake_queues(mphy->hw);
|
|
|
06c887 |
--
|
|
|
06c887 |
2.13.6
|
|
|
06c887 |
|