mirror of
https://github.com/torvalds/linux.git
synced 2026-05-26 08:02:27 +02:00
mt76_sta_state() calls the sta_event callback without holding dev->mutex. However, mt7915_mac_sta_event() (MT7915 implementation of this callback) calls mt7915_mac_twt_teardown_flow() which has lockdep_assert_held(&dev->mt76.mutex) indicating that callers must hold this lock. The locking pattern in mt76_sta_state() is inconsistent: - mt76_sta_add() acquires dev->mutex before calling dev->drv->sta_add - mt76_sta_remove() acquires dev->mutex before calling __mt76_sta_remove - But sta_event callback is called without acquiring the lock Add mutex_lock()/mutex_unlock() around the mt7915_mac_twt_teardown_flow invocation to fix the missing lock protection and maintain consistency with the existing locking pattern. Signed-off-by: Ziyi Guo <n7l8m4@u.northwestern.edu> Link: https://patch.msgid.link/20260131035210.2198259-1-n7l8m4@u.northwestern.edu Signed-off-by: Felix Fietkau <nbd@nbd.name> |
||
|---|---|---|
| .. | ||
| coredump.c | ||
| coredump.h | ||
| debugfs.c | ||
| dma.c | ||
| eeprom.c | ||
| eeprom.h | ||
| init.c | ||
| Kconfig | ||
| mac.c | ||
| mac.h | ||
| main.c | ||
| Makefile | ||
| mcu.c | ||
| mcu.h | ||
| mmio.c | ||
| mt7915.h | ||
| pci.c | ||
| regs.h | ||
| soc.c | ||
| testmode.c | ||
| testmode.h | ||