From 37554e3a6c93e796f3efceebd36b7532d78bce43 Mon Sep 17 00:00:00 2001 From: Mohammed Shafi Shajakhan Date: Fri, 13 May 2011 20:59:42 +0530 Subject: [PATCH] --- yaml --- r: 247673 b: refs/heads/master c: 108697c44b8e50bea3505c6bf9667da4627cb2d5 h: refs/heads/master i: 247671: 2275ddd57ca488ab5954cb6424f0582891e3045a v: v3 --- [refs] | 2 +- trunk/drivers/net/wireless/ath/ath9k/main.c | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/[refs] b/[refs] index 5d8a6dbe4a74..48c640e733a0 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 21e8ee6d207f6d384689571101436eb9070c22ca +refs/heads/master: 108697c44b8e50bea3505c6bf9667da4627cb2d5 diff --git a/trunk/drivers/net/wireless/ath/ath9k/main.c b/trunk/drivers/net/wireless/ath/ath9k/main.c index 33816091b439..45303bdbc465 100644 --- a/trunk/drivers/net/wireless/ath/ath9k/main.c +++ b/trunk/drivers/net/wireless/ath/ath9k/main.c @@ -2276,7 +2276,7 @@ static void ath9k_flush(struct ieee80211_hw *hw, bool drop) timeout = 1; for (j = 0; j < timeout; j++) { - int npend = 0; + bool npend = false; if (j) usleep_range(1000, 2000); @@ -2285,7 +2285,10 @@ static void ath9k_flush(struct ieee80211_hw *hw, bool drop) if (!ATH_TXQ_SETUP(sc, i)) continue; - npend += ath9k_has_pending_frames(sc, &sc->tx.txq[i]); + npend = ath9k_has_pending_frames(sc, &sc->tx.txq[i]); + + if (npend) + break; } if (!npend)