ath9k: Do not use local_bh_disable in ampdu_action
authorSujith Manoharan <c_manoha@qca.qualcomm.com>
Tue, 7 May 2013 23:33:32 +0000 (05:03 +0530)
committerJohn W. Linville <linville@tuxdriver.com>
Wed, 22 May 2013 19:05:33 +0000 (15:05 -0400)
This was added during the early conversion of ampdu_action
to a sleeping callback. There is no need to do this - instead,
use the normal mutex that is acquired for all callbacks.

Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ath/ath9k/main.c

index ec6524aa5178f99df9d5356292efd392ff8ee4f6..e6a30958e94455861160a4a5efae5b93a32f19bf 100644 (file)
@@ -1684,7 +1684,7 @@ static int ath9k_ampdu_action(struct ieee80211_hw *hw,
        struct ath_softc *sc = hw->priv;
        int ret = 0;
 
-       local_bh_disable();
+       mutex_lock(&sc->mutex);
 
        switch (action) {
        case IEEE80211_AMPDU_RX_START:
@@ -1715,7 +1715,7 @@ static int ath9k_ampdu_action(struct ieee80211_hw *hw,
                ath_err(ath9k_hw_common(sc->sc_ah), "Unknown AMPDU action\n");
        }
 
-       local_bh_enable();
+       mutex_unlock(&sc->mutex);
 
        return ret;
 }