Lines Matching refs:wiphy
142 static void _rtl_reg_apply_beaconing_flags(struct wiphy *wiphy, in _rtl_reg_apply_beaconing_flags() argument
153 if (!wiphy->bands[band]) in _rtl_reg_apply_beaconing_flags()
156 sband = wiphy->bands[band]; in _rtl_reg_apply_beaconing_flags()
164 reg_rule = freq_reg_info(wiphy, in _rtl_reg_apply_beaconing_flags()
193 static void _rtl_reg_apply_active_scan_flags(struct wiphy *wiphy, in _rtl_reg_apply_active_scan_flags() argument
201 if (!wiphy->bands[IEEE80211_BAND_2GHZ]) in _rtl_reg_apply_active_scan_flags()
203 sband = wiphy->bands[IEEE80211_BAND_2GHZ]; in _rtl_reg_apply_active_scan_flags()
227 reg_rule = freq_reg_info(wiphy, ch->center_freq); in _rtl_reg_apply_active_scan_flags()
235 reg_rule = freq_reg_info(wiphy, ch->center_freq); in _rtl_reg_apply_active_scan_flags()
247 static void _rtl_reg_apply_radar_flags(struct wiphy *wiphy) in _rtl_reg_apply_radar_flags() argument
253 if (!wiphy->bands[IEEE80211_BAND_5GHZ]) in _rtl_reg_apply_radar_flags()
256 sband = wiphy->bands[IEEE80211_BAND_5GHZ]; in _rtl_reg_apply_radar_flags()
281 static void _rtl_reg_apply_world_flags(struct wiphy *wiphy, in _rtl_reg_apply_world_flags() argument
285 _rtl_reg_apply_beaconing_flags(wiphy, initiator); in _rtl_reg_apply_world_flags()
286 _rtl_reg_apply_active_scan_flags(wiphy, initiator); in _rtl_reg_apply_world_flags()
290 static void _rtl_dump_channel_map(struct wiphy *wiphy) in _rtl_dump_channel_map() argument
298 if (!wiphy->bands[band]) in _rtl_dump_channel_map()
300 sband = wiphy->bands[band]; in _rtl_dump_channel_map()
306 static int _rtl_reg_notifier_apply(struct wiphy *wiphy, in _rtl_reg_notifier_apply() argument
311 _rtl_reg_apply_radar_flags(wiphy); in _rtl_reg_notifier_apply()
319 _rtl_reg_apply_world_flags(wiphy, request->initiator, reg); in _rtl_reg_notifier_apply()
323 _rtl_dump_channel_map(wiphy); in _rtl_reg_notifier_apply()
357 struct wiphy *wiphy, in _rtl_regd_init_wiphy() argument
358 void (*reg_notifier)(struct wiphy *wiphy, in _rtl_regd_init_wiphy() argument
364 wiphy->reg_notifier = reg_notifier; in _rtl_regd_init_wiphy()
366 wiphy->regulatory_flags |= REGULATORY_CUSTOM_REG; in _rtl_regd_init_wiphy()
367 wiphy->regulatory_flags &= ~REGULATORY_STRICT_REG; in _rtl_regd_init_wiphy()
368 wiphy->regulatory_flags &= ~REGULATORY_DISABLE_BEACON_HINTS; in _rtl_regd_init_wiphy()
370 wiphy_apply_custom_regulatory(wiphy, regd); in _rtl_regd_init_wiphy()
371 _rtl_reg_apply_radar_flags(wiphy); in _rtl_regd_init_wiphy()
372 _rtl_reg_apply_world_flags(wiphy, NL80211_REGDOM_SET_BY_DRIVER, reg); in _rtl_regd_init_wiphy()
388 void (*reg_notifier)(struct wiphy *wiphy, in rtl_regd_init() argument
392 struct wiphy *wiphy = hw->wiphy; in rtl_regd_init() local
395 if (wiphy == NULL || &rtlpriv->regd == NULL) in rtl_regd_init()
426 _rtl_regd_init_wiphy(&rtlpriv->regd, wiphy, reg_notifier); in rtl_regd_init()
431 void rtl_reg_notifier(struct wiphy *wiphy, struct regulatory_request *request) in rtl_reg_notifier() argument
433 struct ieee80211_hw *hw = wiphy_to_ieee80211_hw(wiphy); in rtl_reg_notifier()
438 _rtl_reg_notifier_apply(wiphy, request, &rtlpriv->regd); in rtl_reg_notifier()