summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/ath/ath9k/htc_drv_main.c
diff options
context:
space:
mode:
authorSujith <Sujith.Manoharan@atheros.com>2010-05-06 14:45:47 +0530
committerJohn W. Linville <linville@tuxdriver.com>2010-05-07 14:55:52 -0400
commit9c6dda4e2dfea970a7105e3805f0195bc3079f2f (patch)
tree3b255fefdca205e5f38032236faeb1d7e433a2a8 /drivers/net/wireless/ath/ath9k/htc_drv_main.c
parent0aaffa9b9699894aab3266195a529baf9f96ac29 (diff)
ath9k_htc: Fix beaconing in IBSS mode
The current way of managing beaconing in ad-hoc mode has a subtle race - the beacon obtained from mac80211 is freed in the SWBA handler rather than the TX completion routine. But transmission of beacons goes through the normal SKB queue maintained in hif_usb, leading to a situation where __skb_dequeue() in the TX completion handler goes kaput. Fix this by simply getting a beacon from mac80211 for every SWBA and free it in its completion routine. Signed-off-by: Sujith <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/htc_drv_main.c')
-rw-r--r--drivers/net/wireless/ath/ath9k/htc_drv_main.c12
1 files changed, 0 insertions, 12 deletions
diff --git a/drivers/net/wireless/ath/ath9k/htc_drv_main.c b/drivers/net/wireless/ath/ath9k/htc_drv_main.c
index ca7f3a78eb1..7c9e33ba95a 100644
--- a/drivers/net/wireless/ath/ath9k/htc_drv_main.c
+++ b/drivers/net/wireless/ath/ath9k/htc_drv_main.c
@@ -1313,15 +1313,6 @@ static void ath9k_htc_remove_interface(struct ieee80211_hw *hw,
priv->nvifs--;
ath9k_htc_remove_station(priv, vif, NULL);
-
- if (vif->type == NL80211_IFTYPE_ADHOC) {
- spin_lock_bh(&priv->beacon_lock);
- if (priv->beacon)
- dev_kfree_skb_any(priv->beacon);
- priv->beacon = NULL;
- spin_unlock_bh(&priv->beacon_lock);
- }
-
priv->vif = NULL;
mutex_unlock(&priv->mutex);
@@ -1590,9 +1581,6 @@ static void ath9k_htc_bss_info_changed(struct ieee80211_hw *hw,
ath9k_htc_beacon_config(priv, vif);
}
- if (changed & BSS_CHANGED_BEACON)
- ath9k_htc_beacon_update(priv, vif);
-
if ((changed & BSS_CHANGED_BEACON_ENABLED) &&
!bss_conf->enable_beacon) {
priv->op_flags &= ~OP_ENABLE_BEACON;