aboutsummaryrefslogtreecommitdiff
path: root/net/wireless/nl80211.c
diff options
context:
space:
mode:
authorLuis R. Rodriguez <lrodriguez@atheros.com>2009-02-21 00:04:21 -0500
committerJohn W. Linville <linville@tuxdriver.com>2009-02-27 14:52:55 -0500
commita1794390f1afc3631ac056e0f1677b7ab6f7ee74 (patch)
tree0c5ff752ba69c6b002369e340e931ce5ef9df0d3 /net/wireless/nl80211.c
parent85fd129a721e6e892dbaaf05203baf819730f699 (diff)
downloadlinux-a1794390f1afc3631ac056e0f1677b7ab6f7ee74.tar.gz
cfg80211: rename cfg80211_drv_mutex to cfg80211_mutex
cfg80211_drv_mutex is protecting more than the driver list, this renames it and documents what its currently supposed to protect. Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/wireless/nl80211.c')
-rw-r--r--net/wireless/nl80211.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index b176bb80010..88a530f707e 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -256,7 +256,7 @@ static int nl80211_dump_wiphy(struct sk_buff *skb, struct netlink_callback *cb)
int start = cb->args[0];
struct cfg80211_registered_device *dev;
- mutex_lock(&cfg80211_drv_mutex);
+ mutex_lock(&cfg80211_mutex);
list_for_each_entry(dev, &cfg80211_drv_list, list) {
if (++idx <= start)
continue;
@@ -267,7 +267,7 @@ static int nl80211_dump_wiphy(struct sk_buff *skb, struct netlink_callback *cb)
break;
}
}
- mutex_unlock(&cfg80211_drv_mutex);
+ mutex_unlock(&cfg80211_mutex);
cb->args[0] = idx;
@@ -470,7 +470,7 @@ static int nl80211_dump_interface(struct sk_buff *skb, struct netlink_callback *
struct cfg80211_registered_device *dev;
struct wireless_dev *wdev;
- mutex_lock(&cfg80211_drv_mutex);
+ mutex_lock(&cfg80211_mutex);
list_for_each_entry(dev, &cfg80211_drv_list, list) {
if (wp_idx < wp_start) {
wp_idx++;
@@ -497,7 +497,7 @@ static int nl80211_dump_interface(struct sk_buff *skb, struct netlink_callback *
wp_idx++;
}
out:
- mutex_unlock(&cfg80211_drv_mutex);
+ mutex_unlock(&cfg80211_mutex);
cb->args[0] = wp_idx;
cb->args[1] = if_idx;
@@ -1916,9 +1916,9 @@ static int nl80211_req_set_reg(struct sk_buff *skb, struct genl_info *info)
if (is_world_regdom(data))
return -EINVAL;
#endif
- mutex_lock(&cfg80211_drv_mutex);
+ mutex_lock(&cfg80211_mutex);
r = __regulatory_hint(NULL, REGDOM_SET_BY_USER, data, 0, ENVIRON_ANY);
- mutex_unlock(&cfg80211_drv_mutex);
+ mutex_unlock(&cfg80211_mutex);
/* This means the regulatory domain was already set, however
* we don't want to confuse userspace with a "successful error"
* message so lets just treat it as a success */
@@ -2112,7 +2112,7 @@ static int nl80211_get_reg(struct sk_buff *skb, struct genl_info *info)
unsigned int i;
int err = -EINVAL;
- mutex_lock(&cfg80211_drv_mutex);
+ mutex_lock(&cfg80211_mutex);
if (!cfg80211_regdomain)
goto out;
@@ -2175,7 +2175,7 @@ nla_put_failure:
genlmsg_cancel(msg, hdr);
err = -EMSGSIZE;
out:
- mutex_unlock(&cfg80211_drv_mutex);
+ mutex_unlock(&cfg80211_mutex);
return err;
}
@@ -2234,9 +2234,9 @@ static int nl80211_set_reg(struct sk_buff *skb, struct genl_info *info)
BUG_ON(rule_idx != num_rules);
- mutex_lock(&cfg80211_drv_mutex);
+ mutex_lock(&cfg80211_mutex);
r = set_regdom(rd);
- mutex_unlock(&cfg80211_drv_mutex);
+ mutex_unlock(&cfg80211_mutex);
return r;
bad_reg: