ath9k: Fix queue handling
authorSujith <Sujith.Manoharan@atheros.com>
Fri, 8 Jan 2010 05:06:09 +0000 (10:36 +0530)
committerJohn W. Linville <linville@tuxdriver.com>
Tue, 12 Jan 2010 19:02:06 +0000 (14:02 -0500)
The TX queues have to be stopped during an
internal reset. Not handling this would result
in packet loss - fix this.

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

index 974de2056b4a0e9a043f194b954711c5c85e2673..1f7222aef89f04801832280d66bb798af1fa41a1 100644 (file)
@@ -944,6 +944,8 @@ int ath_reset(struct ath_softc *sc, bool retry_tx)
        /* Stop ANI */
        del_timer_sync(&common->ani.timer);
 
+       ieee80211_stop_queues(hw);
+
        ath9k_hw_set_interrupts(ah, 0);
        ath_drain_all_txq(sc, retry_tx);
        ath_stoprecv(sc);
@@ -985,6 +987,8 @@ int ath_reset(struct ath_softc *sc, bool retry_tx)
                }
        }
 
+       ieee80211_wake_queues(hw);
+
        /* Start ANI */
        ath_start_ani(common);