Skip to content

Commit 113f3aa

Browse files
Sriram Rjmberg-intel
authored andcommitted
cfg80211: Prevent regulatory restore during STA disconnect in concurrent interfaces
Currently when an AP and STA interfaces are active in the same or different radios, regulatory settings are restored whenever the STA disconnects. This restores all channel information including dfs states in all radios. For example, if an AP interface is active in one radio and STA in another, when radar is detected on the AP interface, the dfs state of the channel will be changed to UNAVAILABLE. But when the STA interface disconnects, this issues a regulatory disconnect hint which restores all regulatory settings in all the radios attached and thereby losing the stored dfs state on the other radio where the channel was marked as unavailable earlier. Hence prevent such regulatory restore whenever another active beaconing interface is present in the same or other radios. Signed-off-by: Sriram R <[email protected]> Signed-off-by: Johannes Berg <[email protected]>
1 parent 03b7386 commit 113f3aa

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

net/wireless/sme.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -642,11 +642,15 @@ static bool cfg80211_is_all_idle(void)
642642
* All devices must be idle as otherwise if you are actively
643643
* scanning some new beacon hints could be learned and would
644644
* count as new regulatory hints.
645+
* Also if there is any other active beaconing interface we
646+
* need not issue a disconnect hint and reset any info such
647+
* as chan dfs state, etc.
645648
*/
646649
list_for_each_entry(rdev, &cfg80211_rdev_list, list) {
647650
list_for_each_entry(wdev, &rdev->wiphy.wdev_list, list) {
648651
wdev_lock(wdev);
649-
if (wdev->conn || wdev->current_bss)
652+
if (wdev->conn || wdev->current_bss ||
653+
cfg80211_beaconing_iface_active(wdev))
650654
is_all_idle = false;
651655
wdev_unlock(wdev);
652656
}

0 commit comments

Comments
 (0)