Skip to contentSkip to conversation

cfg80211: regulatory: restore proper user alpha2

PATCH Applied Maciej S. Szmigiero 2 participants 2 messages Sep 2, 2015 – Sep 4, 2015

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 cfg80211: regulatory: restore proper user alpha2

restore_regulatory_settings() should restore alpha2 as computed in restore_alpha2(), not raw user_alpha2 to behave as described in the comment just above that code.

This fixes endless loop of calling CRDA for "00" and "97" countries after resume from suspend on my laptop.

Looks like others had the same problem, too:
http://ath9k-devel.ath9k.narkive.com/knY5W6St/ath9k-and-crda-messages-in-logs
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/899335
https://forum.porteus.org/viewtopic.php?t=4975&p=36436
https://forums.opensuse.org/showthread.php/
483356-Authentication-Regulatory-Domain-issues-ath5k-12-2

---
 net/wireless/reg.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
net/wireless/reg.c +1 -1
index 70aef72..7258246 100644
@@ -2625,7 +2625,7 @@ static void restore_regulatory_settings(bool reset_user)
 	 * settings, user regulatory settings takes precedence.
 	 */
 	if (is_an_alpha2(alpha2))
-		regulatory_hint_user(user_alpha2, NL80211_USER_REG_HINT_USER);
+		regulatory_hint_user(alpha2, NL80211_USER_REG_HINT_USER);
 
 	spin_lock(&reg_requests_lock);
 	list_splice_tail_init(&tmp_reg_req_list, &reg_requests_list);
maintainer Applied
#1 lore raw
Quoted 7 lines · Maciej S. Szmigiero

restore_regulatory_settings() should restore alpha2 as computed in restore_alpha2(), not raw user_alpha2 to behave as described in the comment just above that code.

This fixes endless loop of calling CRDA for "00" and "97" countries after resume from suspend on my laptop.

Quoted 8 lines

Looks like others had the same problem, too:
http://ath9k-devel.ath9k.narkive.com/knY5W6St/ath9k-and-crda-messages
-in-logs
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/899335
https://forum.porteus.org/viewtopic.php?t=4975&p=36436
https://forums.opensuse.org/showthread.php/
483356-Authentication-Regulatory-Domain-issues-ath5k-12-2

Applied, thanks.

johannes