History

cfg80211: set custom regdomain after wiphy registration

We used to set regulatory info before the registration of the device and then the regulatory info didn't get set, because the device isn't registered so there isn't a device to set the regulatory info for. So set the regulatory info after the device registration. Call reg_process_self_managed_hints() once again after the device registration because it does nothing before it.

Miri Korenblit committed 5 years ago

Commit 1b7b3ac1 parent 0bc47052 files · +5 −4Browse files

Unified · Split

2 files
  1. net/wireless/core.c +4 −4
  2. net/wireless/reg.c +1 −0
net/wireless/core.c+4−4
@@ -5,7 +5,7 @@ · 4 unmodified lines
55 * Copyright 2006-2010 Johannes Berg <johannes@sipsolutions.net>
66 * Copyright 2013-2014 Intel Mobile Communications GmbH
77 * Copyright 2015-2017 Intel Deutschland GmbH
8− * Copyright (C) 2018-2020 Intel Corporation
8+ * Copyright (C) 2018-2021 Intel Corporation
99 */
1010
1111 #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
@@ -928,9 +928,6 @@ int wiphy_register(struct wiphy *wiphy) · 916 unmodified lines
928928 return res;
929929 }
930930
931− /* set up regulatory info */
932− wiphy_regulatory_register(wiphy);
933−
934931 list_add_rcu(&rdev->list, &cfg80211_rdev_list);
935932 cfg80211_rdev_list_generation++;
936933
@@ -941,6 +938,9 @@ int wiphy_register(struct wiphy *wiphy) · 4 unmodified lines
941938 cfg80211_debugfs_rdev_add(rdev);
942939 nl80211_notify_wiphy(rdev, NL80211_CMD_NEW_WIPHY);
943940
941+ /* set up regulatory info */
942+ wiphy_regulatory_register(wiphy);
943+
944944 if (wiphy->regulatory_flags & REGULATORY_CUSTOM_REG) {
945945 struct regulatory_request request;
946946
net/wireless/reg.c+1−0
@@ -4051,6 +4051,7 @@ void wiphy_regulatory_register(struct wiphy *wiphy) · 4050 unmodified lines
40514051
40524052 wiphy_update_regulatory(wiphy, lr->initiator);
40534053 wiphy_all_share_dfs_chan_state(wiphy);
4054+ reg_process_self_managed_hints();
40544055 }
40554056
40564057 void wiphy_regulatory_deregister(struct wiphy *wiphy)

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t