Lines Matching refs:regd

152 	return rcu_dereference_check(wiphy->regd,  in get_wiphy_regdom()
175 const struct ieee80211_regdomain *regd = NULL; in reg_get_dfs_region() local
180 regd = get_cfg80211_regdom(); in reg_get_dfs_region()
181 dfs_region = regd->dfs_region; in reg_get_dfs_region()
195 if (wiphy_regd->dfs_region == regd->dfs_region) in reg_get_dfs_region()
201 reg_dfs_region_str(regd->dfs_region)); in reg_get_dfs_region()
452 struct ieee80211_regdomain *regd; in reg_copy_regd() local
455 regd = kzalloc(struct_size(regd, reg_rules, src_regd->n_reg_rules), in reg_copy_regd()
457 if (!regd) in reg_copy_regd()
460 memcpy(regd, src_regd, sizeof(struct ieee80211_regdomain)); in reg_copy_regd()
463 memcpy(&regd->reg_rules[i], &src_regd->reg_rules[i], in reg_copy_regd()
466 return regd; in reg_copy_regd()
1155 wiphy->regd) in reg_get_regdomain()
1611 const struct ieee80211_regdomain *regd, u32 bw) in freq_reg_info_regd() argument
1617 if (!regd) in freq_reg_info_regd()
1620 for (i = 0; i < regd->n_reg_rules; i++) { in freq_reg_info_regd()
1624 rr = &regd->reg_rules[i]; in freq_reg_info_regd()
1650 const struct ieee80211_regdomain *regd = reg_get_regdomain(wiphy); in __freq_reg_info() local
1657 reg_rule = freq_reg_info_regd(center_freq, regd, bw); in __freq_reg_info()
1692 static uint32_t reg_rule_to_chan_bw_flags(const struct ieee80211_regdomain *regd, in reg_rule_to_chan_bw_flags() argument
1706 max_bandwidth_khz = reg_get_max_bandwidth(regd, reg_rule); in reg_rule_to_chan_bw_flags()
1784 const struct ieee80211_regdomain *regd; in handle_channel_single_rule() local
1786 regd = reg_get_regdomain(wiphy); in handle_channel_single_rule()
1789 bw_flags = reg_rule_to_chan_bw_flags(regd, reg_rule, chan); in handle_channel_single_rule()
1867 const struct ieee80211_regdomain *regd; in handle_channel_adjacent_rules() local
1869 regd = reg_get_regdomain(wiphy); in handle_channel_adjacent_rules()
1873 bw_flags1 = reg_rule_to_chan_bw_flags(regd, rrule1, chan); in handle_channel_adjacent_rules()
1874 bw_flags2 = reg_rule_to_chan_bw_flags(regd, rrule2, chan); in handle_channel_adjacent_rules()
2150 if (wiphy_strict_alpha2_regd(wiphy) && !wiphy->regd && in ignore_reg_update()
2293 const struct ieee80211_regdomain *regd; in reg_process_ht_flags_channel() local
2316 regd = get_wiphy_regdom(wiphy); in reg_process_ht_flags_channel()
2317 if (regd) { in reg_process_ht_flags_channel()
2320 regd, MHZ_TO_KHZ(20)); in reg_process_ht_flags_channel()
2547 const struct ieee80211_regdomain *regd, in handle_channel_custom() argument
2557 reg_rule = freq_reg_info_regd(center_freq_khz, regd, bw); in handle_channel_custom()
2575 bw_flags = reg_rule_to_chan_bw_flags(regd, reg_rule, chan); in handle_channel_custom()
2607 const struct ieee80211_regdomain *regd) in handle_band_custom() argument
2620 handle_channel_custom(wiphy, &sband->channels[i], regd, in handle_band_custom()
2626 const struct ieee80211_regdomain *regd) in wiphy_apply_custom_regulatory() argument
2639 handle_band_custom(wiphy, wiphy->bands[band], regd); in wiphy_apply_custom_regulatory()
2648 new_regd = reg_copy_regd(regd); in wiphy_apply_custom_regulatory()
2655 rcu_assign_pointer(wiphy->regd, new_regd); in wiphy_apply_custom_regulatory()
2809 const struct ieee80211_regdomain *regd, *tmp; in reg_process_hint_driver() local
2821 regd = reg_copy_regd(get_cfg80211_regdom()); in reg_process_hint_driver()
2822 if (IS_ERR(regd)) in reg_process_hint_driver()
2828 rcu_assign_pointer(wiphy->regd, regd); in reg_process_hint_driver()
2955 wiphy1_regd = rcu_dereference(wiphy1->regd); in reg_dfs_domain_same()
2959 wiphy2_regd = rcu_dereference(wiphy2->regd); in reg_dfs_domain_same()
3165 const struct ieee80211_regdomain *regd; in reg_process_self_managed_hint() local
3173 regd = rdev->requested_regd; in reg_process_self_managed_hint()
3177 if (!regd) in reg_process_self_managed_hint()
3181 rcu_assign_pointer(wiphy->regd, regd); in reg_process_self_managed_hint()
3185 handle_band_custom(wiphy, wiphy->bands[band], regd); in reg_process_self_managed_hint()
3190 request.alpha2[0] = regd->alpha2[0]; in reg_process_self_managed_hint()
3191 request.alpha2[1] = regd->alpha2[1]; in reg_process_self_managed_hint()
3859 const struct ieee80211_regdomain *regd; in reg_set_rd_driver() local
3884 if (request_wiphy->regd) in reg_set_rd_driver()
3887 regd = reg_copy_regd(rd); in reg_set_rd_driver()
3888 if (IS_ERR(regd)) in reg_set_rd_driver()
3889 return PTR_ERR(regd); in reg_set_rd_driver()
3891 rcu_assign_pointer(request_wiphy->regd, regd); in reg_set_rd_driver()
3909 rcu_assign_pointer(request_wiphy->regd, rd); in reg_set_rd_driver()
4032 const struct ieee80211_regdomain *regd; in __regulatory_set_wiphy_regd() local
4050 regd = reg_copy_regd(rd); in __regulatory_set_wiphy_regd()
4051 if (IS_ERR(regd)) in __regulatory_set_wiphy_regd()
4052 return PTR_ERR(regd); in __regulatory_set_wiphy_regd()
4058 rdev->requested_regd = regd; in __regulatory_set_wiphy_regd()
4133 RCU_INIT_POINTER(wiphy->regd, NULL); in wiphy_regulatory_deregister()
4198 const struct ieee80211_regdomain *regd = NULL; in regulatory_pre_cac_allowed() local
4204 regd = rcu_dereference(cfg80211_regdomain); in regulatory_pre_cac_allowed()
4205 wiphy_regd = rcu_dereference(wiphy->regd); in regulatory_pre_cac_allowed()
4207 if (regd->dfs_region == NL80211_DFS_ETSI) in regulatory_pre_cac_allowed()
4215 if (regd->dfs_region == wiphy_regd->dfs_region && in regulatory_pre_cac_allowed()