This splits up wiphy_update_regulatory() in two parts, the first can be used by other internal cfg80211 regulatory routines to avoid calling the reg_notifier() if not needed. Signed-off-by: Luis R. Rodriguez <lrodriguez@xxxxxxxxxxx> --- net/wireless/reg.c | 7 ++++++- 1 files changed, 6 insertions(+), 1 deletions(-) diff --git a/net/wireless/reg.c b/net/wireless/reg.c index 49c9c25..127bec2 100644 --- a/net/wireless/reg.c +++ b/net/wireless/reg.c @@ -963,13 +963,18 @@ static void update_all_wiphy_regulatory(enum reg_set_by setby) wiphy_update_regulatory(&drv->wiphy, setby); } -void wiphy_update_regulatory(struct wiphy *wiphy, enum reg_set_by setby) +static void regd_update_regulatory(struct wiphy *wiphy) { enum ieee80211_band band; for (band = 0; band < IEEE80211_NUM_BANDS; band++) { if (wiphy->bands[band]) handle_band(wiphy, band); } +} + +void wiphy_update_regulatory(struct wiphy *wiphy, enum reg_set_by setby) +{ + regd_update_regulatory(wiphy); if (wiphy->reg_notifier) wiphy->reg_notifier(wiphy, setby); } -- 1.6.1.rc3.51.g5832d -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html