Thread (67 messages) 67 messages, 7 authors, 2018-09-05
STALE2823d

[RESEND PATCH v2 7/9] cfg80211: reg: Init wiphy_idx in regulatory_hint_core()

From: Luca Coelho <hidden>
Date: 2018-09-05 09:34:49
Subsystem: 802.11 (including cfg80211/nl80211), the rest · Maintainers: Johannes Berg, Linus Torvalds

From: Andrei Otcheretianski <redacted>

Core regulatory hints didn't set wiphy_idx to WIPHY_IDX_INVALID. Since
the regulatory request is zeroed, wiphy_idx was always implicitly set to
0. This resulted in updating only phy #0.
Fix that.

Signed-off-by: Andrei Otcheretianski <redacted>
Signed-off-by: Luca Coelho <redacted>
---
 net/wireless/reg.c | 1 +
 1 file changed, 1 insertion(+)
diff --git a/net/wireless/reg.c b/net/wireless/reg.c
index 043d43573ca2..0eb5e44f8a74 100644
--- a/net/wireless/reg.c
+++ b/net/wireless/reg.c
@@ -2932,6 +2932,7 @@ static int regulatory_hint_core(const char *alpha2)
 	request->alpha2[0] = alpha2[0];
 	request->alpha2[1] = alpha2[1];
 	request->initiator = NL80211_REGDOM_SET_BY_CORE;
+	request->wiphy_idx = WIPHY_IDX_INVALID;
 
 	queue_regulatory_request(request);
 
-- 
2.18.0
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help