wifi: rtw88: Call rtw_fw_beacon_filter_config() with rtwdev->mutex held
authorSascha Hauer <s.hauer@pengutronix.de>
Fri, 2 Dec 2022 08:12:15 +0000 (09:12 +0100)
committerKalle Valo <kvalo@kernel.org>
Thu, 8 Dec 2022 14:48:40 +0000 (16:48 +0200)
rtw_fw_beacon_filter_config() is called once with rtwdev->mutex held
and once without the mutex held. Call it consistently with rtwdev->mutex
held.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Reviewed-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20221202081224.2779981-3-s.hauer@pengutronix.de
drivers/net/wireless/realtek/rtw88/mac80211.c

index 07578ccc4bab3bd6e520c667e6b01787712d7f68..776a9a9884b5d9419944a216869d8f33ef763fe0 100644 (file)
@@ -487,8 +487,8 @@ static int rtw_ops_sta_remove(struct ieee80211_hw *hw,
 {
        struct rtw_dev *rtwdev = hw->priv;
 
-       rtw_fw_beacon_filter_config(rtwdev, false, vif);
        mutex_lock(&rtwdev->mutex);
+       rtw_fw_beacon_filter_config(rtwdev, false, vif);
        rtw_sta_remove(rtwdev, sta, true);
        mutex_unlock(&rtwdev->mutex);