diff options
author | Luis R. Rodriguez <mcgrof@qca.qualcomm.com> | 2012-07-12 11:49:21 -0700 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2012-07-17 12:16:41 +0200 |
commit | 14cdf112019c1d4bc0f1bf9a9c832be641dbe25a (patch) | |
tree | a87627bd88a2f07322e06c08f6448ac240f64f61 /net/wireless | |
parent | f8a1c774570ab50f1657083c990b968d5f7f22cb (diff) | |
download | op-kernel-dev-14cdf112019c1d4bc0f1bf9a9c832be641dbe25a.zip op-kernel-dev-14cdf112019c1d4bc0f1bf9a9c832be641dbe25a.tar.gz |
cfg80211: remove regulatory_update()
regulatory_update() just calls wiphy_update_regulatory().
wiphy_update_regulatory() assumes you already have
the reg_mutex held so just move the call within locking
context and kill the superfluous regulatory_update().
Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/wireless')
-rw-r--r-- | net/wireless/reg.c | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/net/wireless/reg.c b/net/wireless/reg.c index be6880f..dbb01df 100644 --- a/net/wireless/reg.c +++ b/net/wireless/reg.c @@ -1232,14 +1232,6 @@ static void wiphy_update_regulatory(struct wiphy *wiphy, wiphy->reg_notifier(wiphy, last_request); } -static void regulatory_update(struct wiphy *wiphy, - enum nl80211_reg_initiator setby) -{ - mutex_lock(®_mutex); - wiphy_update_regulatory(wiphy, setby); - mutex_unlock(®_mutex); -} - static void update_all_wiphy_regulatory(enum nl80211_reg_initiator initiator) { struct cfg80211_registered_device *rdev; @@ -2387,9 +2379,9 @@ void wiphy_regulatory_register(struct wiphy *wiphy) if (!reg_dev_ignore_cell_hint(wiphy)) reg_num_devs_support_basehint++; - mutex_unlock(®_mutex); + wiphy_update_regulatory(wiphy, NL80211_REGDOM_SET_BY_CORE); - regulatory_update(wiphy, NL80211_REGDOM_SET_BY_CORE); + mutex_unlock(®_mutex); } /* Caller must hold cfg80211_mutex */ |