linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] ath9k: fix possible hang on flush
@ 2014-04-21 23:14 Tim Harvey
  2014-04-21 23:14 ` [PATCH 2/2] ath9k: add a recv budget Tim Harvey
  2014-04-29 12:02 ` [PATCH 1/2] ath9k: fix possible hang on flush Tim Harvey
  0 siblings, 2 replies; 7+ messages in thread
From: Tim Harvey @ 2014-04-21 23:14 UTC (permalink / raw)
  To: linux-wireless; +Cc: linville, nbd

If a flush is requested, make sure to clear the descriptor once we've
processed it.

This resolves a hang that will occur if all RX descriptors are full when a
flush is requested.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
---
 drivers/net/wireless/ath/ath9k/recv.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/net/wireless/ath/ath9k/recv.c b/drivers/net/wireless/ath/ath9k/recv.c
index 6c9accd..e77a253 100644
--- a/drivers/net/wireless/ath/ath9k/recv.c
+++ b/drivers/net/wireless/ath/ath9k/recv.c
@@ -1113,14 +1113,13 @@ requeue_drop_frag:
 		}
 requeue:
 		list_add_tail(&bf->list, &sc->rx.rxbuf);
-		if (flush)
-			continue;
 
 		if (edma) {
 			ath_rx_edma_buf_link(sc, qtype);
 		} else {
 			ath_rx_buf_relink(sc, bf);
-			ath9k_hw_rxena(ah);
+			if (!flush)
+				ath9k_hw_rxena(ah);
 		}
 	} while (1);
 
-- 
1.8.3.2


^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2014-04-29 19:24 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-04-21 23:14 [PATCH 1/2] ath9k: fix possible hang on flush Tim Harvey
2014-04-21 23:14 ` [PATCH 2/2] ath9k: add a recv budget Tim Harvey
2014-04-22  9:09   ` Felix Fietkau
2014-04-29 12:04     ` Tim Harvey
2014-04-29 12:25       ` Felix Fietkau
2014-04-29 19:23   ` Adrian Chadd
2014-04-29 12:02 ` [PATCH 1/2] ath9k: fix possible hang on flush Tim Harvey

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).