diff options
author | John W. Linville <linville@tuxdriver.com> | 2010-07-29 14:47:07 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2010-07-29 14:47:07 -0400 |
commit | ae3568adf42d5d3bb3cfa505b94351c5d1ce4924 (patch) | |
tree | 112865a6e6b1e4ddf70362f3efb295c495ec85b9 /net/mac80211/cfg.c | |
parent | 7f3e01fee41a322747db2d7574516d9fbd3785c0 (diff) | |
parent | b7753c8cd51dce67a0b152efb456a21ff1cc241b (diff) | |
download | blackbird-obmc-linux-ae3568adf42d5d3bb3cfa505b94351c5d1ce4924.tar.gz blackbird-obmc-linux-ae3568adf42d5d3bb3cfa505b94351c5d1ce4924.zip |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6 into for-davem
Diffstat (limited to 'net/mac80211/cfg.c')
-rw-r--r-- | net/mac80211/cfg.c | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c index db4d9340c846..29ac8e1a509e 100644 --- a/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c @@ -158,7 +158,7 @@ static int ieee80211_add_key(struct wiphy *wiphy, struct net_device *dev, if (mac_addr) { sta = sta_info_get_bss(sdata, mac_addr); if (!sta) { - ieee80211_key_free(key); + ieee80211_key_free(sdata->local, key); err = -ENOENT; goto out_unlock; } @@ -192,7 +192,7 @@ static int ieee80211_del_key(struct wiphy *wiphy, struct net_device *dev, goto out_unlock; if (sta->key) { - ieee80211_key_free(sta->key); + ieee80211_key_free(sdata->local, sta->key); WARN_ON(sta->key); ret = 0; } @@ -205,7 +205,7 @@ static int ieee80211_del_key(struct wiphy *wiphy, struct net_device *dev, goto out_unlock; } - ieee80211_key_free(sdata->keys[key_idx]); + ieee80211_key_free(sdata->local, sdata->keys[key_idx]); WARN_ON(sdata->keys[key_idx]); ret = 0; @@ -324,15 +324,10 @@ static int ieee80211_config_default_mgmt_key(struct wiphy *wiphy, struct net_device *dev, u8 key_idx) { - struct ieee80211_sub_if_data *sdata; - - rcu_read_lock(); + struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev); - sdata = IEEE80211_DEV_TO_SUB_IF(dev); ieee80211_set_default_mgmt_key(sdata, key_idx); - rcu_read_unlock(); - return 0; } |