Skip to content

Commit 2170e21

Browse files
nbd168Kalle Valo
authored andcommitted
mt76: mt7603: add missing initialization for dev->ps_lock
Fixes lockdep complaint and a potential race condition Signed-off-by: Felix Fietkau <[email protected]> Signed-off-by: Kalle Valo <[email protected]>
1 parent 4837696 commit 2170e21

File tree

1 file changed

+2
-0
lines changed
  • drivers/net/wireless/mediatek/mt76/mt7603

1 file changed

+2
-0
lines changed

drivers/net/wireless/mediatek/mt76/mt7603/init.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -510,6 +510,8 @@ int mt7603_register_device(struct mt7603_dev *dev)
510510
bus_ops->rmw = mt7603_rmw;
511511
dev->mt76.bus = bus_ops;
512512

513+
spin_lock_init(&dev->ps_lock);
514+
513515
INIT_DELAYED_WORK(&dev->mac_work, mt7603_mac_work);
514516
tasklet_init(&dev->pre_tbtt_tasklet, mt7603_pre_tbtt_tasklet,
515517
(unsigned long)dev);

0 commit comments

Comments
 (0)