diff options
author | Felix Fietkau <nbd@nbd.name> | 2019-03-26 11:34:19 +0300 |
---|---|---|
committer | Kalle Valo <kvalo@codeaurora.org> | 2019-04-12 21:28:25 +0300 |
commit | 2170e2157d7c5398f84477935553d63a93a1f6b8 (patch) | |
tree | 30afe6ffa8cf4d0bd109f2294438941a388a5888 /drivers/net/wireless/mediatek/mt76/mt7603 | |
parent | 4837696f6b5451242b2095764287b6336e844683 (diff) | |
download | linux-2170e2157d7c5398f84477935553d63a93a1f6b8.tar.xz |
mt76: mt7603: add missing initialization for dev->ps_lock
Fixes lockdep complaint and a potential race condition
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Diffstat (limited to 'drivers/net/wireless/mediatek/mt76/mt7603')
-rw-r--r-- | drivers/net/wireless/mediatek/mt76/mt7603/init.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/wireless/mediatek/mt76/mt7603/init.c b/drivers/net/wireless/mediatek/mt76/mt7603/init.c index d54dda67d036..3af45949e868 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7603/init.c +++ b/drivers/net/wireless/mediatek/mt76/mt7603/init.c @@ -510,6 +510,8 @@ int mt7603_register_device(struct mt7603_dev *dev) bus_ops->rmw = mt7603_rmw; dev->mt76.bus = bus_ops; + spin_lock_init(&dev->ps_lock); + INIT_DELAYED_WORK(&dev->mac_work, mt7603_mac_work); tasklet_init(&dev->pre_tbtt_tasklet, mt7603_pre_tbtt_tasklet, (unsigned long)dev); |