diff options
author | David S. Miller <davem@davemloft.net> | 2009-04-30 05:30:35 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-04-30 05:30:35 +0200 |
commit | aba7453037c3a90714caae77a622dceaf1173786 (patch) | |
tree | bf07f9f432b0d8e9db9486f1f32ad065c0aa7c5c /net/mac80211/main.c | |
parent | Revert "vxge: use max() instead of VXGE_HW_SET_LEVEL" (diff) | |
parent | mv643xx_eth: 64bit mib counter read fix (diff) | |
download | linux-aba7453037c3a90714caae77a622dceaf1173786.tar.xz linux-aba7453037c3a90714caae77a622dceaf1173786.zip |
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts:
Documentation/isdn/00-INDEX
drivers/net/wireless/iwlwifi/iwl-scan.c
drivers/net/wireless/rndis_wlan.c
net/mac80211/main.c
Diffstat (limited to 'net/mac80211/main.c')
-rw-r--r-- | net/mac80211/main.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/net/mac80211/main.c b/net/mac80211/main.c index 5320e08434ac..5ca62ea15079 100644 --- a/net/mac80211/main.c +++ b/net/mac80211/main.c @@ -779,6 +779,7 @@ struct ieee80211_hw *ieee80211_alloc_hw(size_t priv_data_len, local->hw.conf.long_frame_max_tx_count = wiphy->retry_long; local->hw.conf.short_frame_max_tx_count = wiphy->retry_short; local->hw.conf.radio_enabled = true; + local->user_power_level = -1; INIT_LIST_HEAD(&local->interfaces); mutex_init(&local->iflist_mtx); @@ -981,6 +982,13 @@ int ieee80211_register_hw(struct ieee80211_hw *hw) if (result < 0) goto fail_sta_info; + result = ieee80211_wep_init(local); + if (result < 0) { + printk(KERN_DEBUG "%s: Failed to initialize wep: %d\n", + wiphy_name(local->hw.wiphy), result); + goto fail_wep; + } + rtnl_lock(); result = dev_alloc_name(local->mdev, local->mdev->name); if (result < 0) @@ -1002,14 +1010,6 @@ int ieee80211_register_hw(struct ieee80211_hw *hw) goto fail_rate; } - result = ieee80211_wep_init(local); - - if (result < 0) { - printk(KERN_DEBUG "%s: Failed to initialize wep: %d\n", - wiphy_name(local->hw.wiphy), result); - goto fail_wep; - } - /* add one default STA interface if supported */ if (local->hw.wiphy->interface_modes & BIT(NL80211_IFTYPE_STATION)) { result = ieee80211_if_add(local, "wlan%d", NULL, @@ -1052,13 +1052,13 @@ int ieee80211_register_hw(struct ieee80211_hw *hw) fail_pm_qos: ieee80211_led_exit(local); ieee80211_remove_interfaces(local); - fail_wep: - rate_control_deinitialize(local); fail_rate: unregister_netdevice(local->mdev); local->mdev = NULL; fail_dev: rtnl_unlock(); + ieee80211_wep_free(local); + fail_wep: sta_info_stop(local); fail_sta_info: debugfs_hw_del(local); |