ath9k: reserve a beacon slot on beaconing vif addition
authorRajkumar Manoharan <rmanoharan@atheros.com>
Tue, 1 Feb 2011 17:35:36 +0000 (23:05 +0530)
committerJohn W. Linville <linville@tuxdriver.com>
Thu, 3 Feb 2011 21:45:29 +0000 (16:45 -0500)
The beaconing vif addition is based on max beacon slot
available. So it is better to reserve a beacon slot
on interface addition and let it be configured properly
on bss_info change.

Signed-off-by: Rajkumar Manoharan <rmanoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ath/ath9k/main.c

index c9925e9..e5c695d 100644 (file)
@@ -1419,9 +1419,7 @@ static void ath9k_do_vif_add_setup(struct ieee80211_hw *hw,
                 * there.
                 */
                error = ath_beacon_alloc(sc, vif);
-               if (error)
-                       ath9k_reclaim_beacon(sc, vif);
-               else
+               if (!error)
                        ath_beacon_config(sc, vif);
        }
 }