diff options
author | Johannes Berg <johannes@sipsolutions.net> | 2009-12-23 07:15:43 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-12-28 16:55:05 -0500 |
commit | e4da8c37af626001ff704fb29ea14eb58f5f7208 (patch) | |
tree | d56bf3a225979b18370183eb9c39f66d8e524069 /net/mac80211/mlme.c | |
parent | b8bc4b0aa9bfba755c64b11b8f60e6cfab25dc9d (diff) |
mac80211: make off-channel work generic
This changes mac80211 to allow being off-channel for
any type of work, not just the 'remain-on-channel'
work. This also helps fast transition to a BSS on a
different channel.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/mlme.c')
-rw-r--r-- | net/mac80211/mlme.c | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c index 32d6e6614f9f..72920ee07885 100644 --- a/net/mac80211/mlme.c +++ b/net/mac80211/mlme.c | |||
@@ -1105,6 +1105,8 @@ static bool ieee80211_assoc_success(struct ieee80211_work *wk, | |||
1105 | else | 1105 | else |
1106 | ieee80211_set_wmm_default(sdata); | 1106 | ieee80211_set_wmm_default(sdata); |
1107 | 1107 | ||
1108 | local->oper_channel = wk->chan; | ||
1109 | |||
1108 | if (elems.ht_info_elem && elems.wmm_param && | 1110 | if (elems.ht_info_elem && elems.wmm_param && |
1109 | (sdata->local->hw.queues >= 4) && | 1111 | (sdata->local->hw.queues >= 4) && |
1110 | !(ifmgd->flags & IEEE80211_STA_DISABLE_11N)) | 1112 | !(ifmgd->flags & IEEE80211_STA_DISABLE_11N)) |
@@ -1797,15 +1799,6 @@ int ieee80211_mgd_auth(struct ieee80211_sub_if_data *sdata, | |||
1797 | wk->sdata = sdata; | 1799 | wk->sdata = sdata; |
1798 | wk->done = ieee80211_probe_auth_done; | 1800 | wk->done = ieee80211_probe_auth_done; |
1799 | 1801 | ||
1800 | /* | ||
1801 | * XXX: if still associated need to tell AP that we're going | ||
1802 | * to sleep and then change channel etc. | ||
1803 | * For now switch channel here, later will be handled | ||
1804 | * by submitting this as an off-channel work item. | ||
1805 | */ | ||
1806 | sdata->local->oper_channel = req->bss->channel; | ||
1807 | ieee80211_hw_config(sdata->local, 0); | ||
1808 | |||
1809 | ieee80211_add_work(wk); | 1802 | ieee80211_add_work(wk); |
1810 | return 0; | 1803 | return 0; |
1811 | } | 1804 | } |
@@ -1929,9 +1922,6 @@ int ieee80211_mgd_assoc(struct ieee80211_sub_if_data *sdata, | |||
1929 | else | 1922 | else |
1930 | ifmgd->flags &= ~IEEE80211_STA_CONTROL_PORT; | 1923 | ifmgd->flags &= ~IEEE80211_STA_CONTROL_PORT; |
1931 | 1924 | ||
1932 | sdata->local->oper_channel = req->bss->channel; | ||
1933 | ieee80211_hw_config(sdata->local, 0); | ||
1934 | |||
1935 | ieee80211_add_work(wk); | 1925 | ieee80211_add_work(wk); |
1936 | return 0; | 1926 | return 0; |
1937 | } | 1927 | } |