Merge tag 'printk-for-5.20-sane' of git://git.kernel.org/pub/scm/linux/kernel/git...
[linux-2.6-microblaze.git] / net / mac80211 / ibss.c
index e8df4ce..d56890e 100644 (file)
@@ -351,10 +351,8 @@ static void __ieee80211_sta_join_ibss(struct ieee80211_sub_if_data *sdata,
        bss_change |= BSS_CHANGED_ERP_SLOT;
 
        /* cf. IEEE 802.11 9.2.12 */
-       if (chan->band == NL80211_BAND_2GHZ && have_higher_than_11mbit)
-               sdata->flags |= IEEE80211_SDATA_OPERATING_GMODE;
-       else
-               sdata->flags &= ~IEEE80211_SDATA_OPERATING_GMODE;
+       sdata->deflink.operating_11g_mode =
+               chan->band == NL80211_BAND_2GHZ && have_higher_than_11mbit;
 
        ieee80211_set_wmm_default(&sdata->deflink, true, false);
 
@@ -627,7 +625,7 @@ ieee80211_ibss_add_sta(struct ieee80211_sub_if_data *sdata, const u8 *bssid,
        scan_width = cfg80211_chandef_to_scan_width(&chanctx_conf->def);
        rcu_read_unlock();
 
-       sta = sta_info_alloc(sdata, addr, -1, GFP_KERNEL);
+       sta = sta_info_alloc(sdata, addr, GFP_KERNEL);
        if (!sta) {
                rcu_read_lock();
                return NULL;
@@ -1228,7 +1226,7 @@ void ieee80211_ibss_rx_no_sta(struct ieee80211_sub_if_data *sdata,
        scan_width = cfg80211_chandef_to_scan_width(&chanctx_conf->def);
        rcu_read_unlock();
 
-       sta = sta_info_alloc(sdata, addr, -1, GFP_ATOMIC);
+       sta = sta_info_alloc(sdata, addr, GFP_ATOMIC);
        if (!sta)
                return;