Commit c492db37 authored by Johannes Berg's avatar Johannes Berg

regulatory: use RCU to protect last_request

This will allow making freq_reg_info() lock-free.
Acked-by: default avatarLuis R. Rodriguez <mcgrof@do-not-panic.com>
Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
parent 458f4f9e
...@@ -36,6 +36,7 @@ enum environment_cap { ...@@ -36,6 +36,7 @@ enum environment_cap {
/** /**
* struct regulatory_request - used to keep track of regulatory requests * struct regulatory_request - used to keep track of regulatory requests
* *
* @rcu_head: RCU head struct used to free the request
* @wiphy_idx: this is set if this request's initiator is * @wiphy_idx: this is set if this request's initiator is
* %REGDOM_SET_BY_COUNTRY_IE or %REGDOM_SET_BY_DRIVER. This * %REGDOM_SET_BY_COUNTRY_IE or %REGDOM_SET_BY_DRIVER. This
* can be used by the wireless core to deal with conflicts * can be used by the wireless core to deal with conflicts
...@@ -73,6 +74,7 @@ enum environment_cap { ...@@ -73,6 +74,7 @@ enum environment_cap {
* @list: used to insert into the reg_requests_list linked list * @list: used to insert into the reg_requests_list linked list
*/ */
struct regulatory_request { struct regulatory_request {
struct rcu_head rcu_head;
int wiphy_idx; int wiphy_idx;
enum nl80211_reg_initiator initiator; enum nl80211_reg_initiator initiator;
enum nl80211_user_reg_hint_type user_reg_hint_type; enum nl80211_user_reg_hint_type user_reg_hint_type;
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment