mac80211: allocate only one RX queue
[deliverable/linux.git] / net / mac80211 / iface.c
index 4054399be907f8be54d07cf786afc5693e562982..236d15841812e86b60c488c4fd45311fb3fca885 100644 (file)
@@ -384,11 +384,11 @@ static void ieee80211_do_stop(struct ieee80211_sub_if_data *sdata,
        int i;
        enum nl80211_channel_type orig_ct;
 
+       clear_bit(SDATA_STATE_RUNNING, &sdata->state);
+
        if (local->scan_sdata == sdata)
                ieee80211_scan_cancel(local);
 
-       clear_bit(SDATA_STATE_RUNNING, &sdata->state);
-
        /*
         * Stop TX on this interface first.
         */
@@ -449,7 +449,8 @@ static void ieee80211_do_stop(struct ieee80211_sub_if_data *sdata,
        /* APs need special treatment */
        if (sdata->vif.type == NL80211_IFTYPE_AP) {
                struct ieee80211_sub_if_data *vlan, *tmpsdata;
-               struct beacon_data *old_beacon = sdata->u.ap.beacon;
+               struct beacon_data *old_beacon =
+                       rtnl_dereference(sdata->u.ap.beacon);
 
                /* sdata_running will return false, so this will disable */
                ieee80211_bss_info_change_notify(sdata,
@@ -1129,8 +1130,8 @@ int ieee80211_if_add(struct ieee80211_local *local, const char *name,
 
        ASSERT_RTNL();
 
-       ndev = alloc_netdev_mq(sizeof(*sdata) + local->hw.vif_data_size,
-                              name, ieee80211_if_setup, local->hw.queues);
+       ndev = alloc_netdev_mqs(sizeof(*sdata) + local->hw.vif_data_size,
+                               name, ieee80211_if_setup, local->hw.queues, 1);
        if (!ndev)
                return -ENOMEM;
        dev_net_set(ndev, wiphy_net(local->hw.wiphy));
This page took 0.027083 seconds and 5 git commands to generate.