]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
mac80211: use fixed channel in ibss join when appropriate
authorJohannes Berg <johannes@sipsolutions.net>
Wed, 5 May 2010 13:33:55 +0000 (15:33 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Wed, 5 May 2010 19:10:57 +0000 (15:10 -0400)
"mac80211: improve IBSS scanning" was missing a hunk.
This adds that hunk as originally intended.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
net/mac80211/ibss.c

index ba752362b2b2627a123f204e6dc7ce304c2f6a56..d5855ae387e89d969b7f80187b7ad96feba43926 100644 (file)
@@ -907,6 +907,12 @@ int ieee80211_ibss_join(struct ieee80211_sub_if_data *sdata,
        sdata->u.ibss.channel = params->channel;
        sdata->u.ibss.fixed_channel = params->channel_fixed;
 
+       /* fix ourselves to that channel now already */
+       if (params->channel_fixed) {
+               sdata->local->oper_channel = params->channel;
+               sdata->local->oper_channel_type = NL80211_CHAN_NO_HT;
+       }
+
        if (params->ie) {
                sdata->u.ibss.ie = kmemdup(params->ie, params->ie_len,
                                           GFP_KERNEL);