diff options
author | Lorenzo Bianconi <lorenzo@kernel.org> | 2021-04-18 18:45:30 +0200 |
---|---|---|
committer | Felix Fietkau <nbd@nbd.name> | 2021-04-21 20:55:52 +0200 |
commit | 9800462ddc58ace3d96a006156ba6764824992f2 (patch) | |
tree | cd9f3ef181f6e478374c6e4a0d8009492b5fa77b /drivers/net/wireless/mediatek/mt76/mt7921/init.c | |
parent | 7f2bc8ba11a0e82d474f0047933c3baeebf4406c (diff) |
mt76: mt7921: rely on mt76_connac_pm_ref/mt76_connac_pm_unref in tx path
Introduce mt7921_tx_worker routine as mt76 tx worker callback for
mt7921.
Rely on mt76_connac_pm_ref/mt76_connac_pm_unref to check PM state and
increment/decrement wake counter
Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'drivers/net/wireless/mediatek/mt76/mt7921/init.c')
-rw-r--r-- | drivers/net/wireless/mediatek/mt76/mt7921/init.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/wireless/mediatek/mt76/mt7921/init.c b/drivers/net/wireless/mediatek/mt76/mt7921/init.c index 0b8a5a7f4362..ce0e231ab772 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7921/init.c +++ b/drivers/net/wireless/mediatek/mt76/mt7921/init.c @@ -219,9 +219,11 @@ int mt7921_register_device(struct mt7921_dev *dev) dev->phy.dev = dev; dev->phy.mt76 = &dev->mt76.phy; dev->mt76.phy.priv = &dev->phy; + dev->mt76.tx_worker.fn = mt7921_tx_worker; INIT_DELAYED_WORK(&dev->pm.ps_work, mt7921_pm_power_save_work); INIT_WORK(&dev->pm.wake_work, mt7921_pm_wake_work); + spin_lock_init(&dev->pm.wake.lock); mutex_init(&dev->pm.mutex); init_completion(&dev->pm.wake_cmpl); spin_lock_init(&dev->pm.txq_lock); |