netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] rt2x00: use rt2x00queue_flush_queues() instead of implementing the same action
@ 2015-03-07 18:45 Giedrius Statkevičius
  2015-03-08 10:37 ` Stanislaw Gruszka
  0 siblings, 1 reply; 2+ messages in thread
From: Giedrius Statkevičius @ 2015-03-07 18:45 UTC (permalink / raw)
  To: sgruszka
  Cc: helmut.schaa, kvalo, linux-wireless, users, netdev, linux-kernel,
	Giedrius Statkevičius

Use rt2x00queue_flush_queues() in rt2x00mac_flush() instead of
reimplementing the same actions the second time. Also, now it flushes
the rx queue aswell which it didn't before and that makes it completely
do what it's supposed to do according to struct iee80211_ops: flush()
must flush all queues.

Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@gmail.com>
---
 drivers/net/wireless/rt2x00/rt2x00mac.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/net/wireless/rt2x00/rt2x00mac.c b/drivers/net/wireless/rt2x00/rt2x00mac.c
index 300876d..5bc48c3 100644
--- a/drivers/net/wireless/rt2x00/rt2x00mac.c
+++ b/drivers/net/wireless/rt2x00/rt2x00mac.c
@@ -756,13 +756,11 @@ void rt2x00mac_flush(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
 		     u32 queues, bool drop)
 {
 	struct rt2x00_dev *rt2x00dev = hw->priv;
-	struct data_queue *queue;
 
 	if (!test_bit(DEVICE_STATE_PRESENT, &rt2x00dev->flags))
 		return;
 
-	tx_queue_for_each(rt2x00dev, queue)
-		rt2x00queue_flush_queue(queue, drop);
+	rt2x00queue_flush_queues(rt2x00dev, drop);
 }
 EXPORT_SYMBOL_GPL(rt2x00mac_flush);
 
-- 
2.3.1

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

* Re: [PATCH] rt2x00: use rt2x00queue_flush_queues() instead of implementing the same action
  2015-03-07 18:45 [PATCH] rt2x00: use rt2x00queue_flush_queues() instead of implementing the same action Giedrius Statkevičius
@ 2015-03-08 10:37 ` Stanislaw Gruszka
  0 siblings, 0 replies; 2+ messages in thread
From: Stanislaw Gruszka @ 2015-03-08 10:37 UTC (permalink / raw)
  To: Giedrius Statkevičius
  Cc: helmut.schaa, kvalo, linux-wireless, users, netdev, linux-kernel

On Sat, Mar 07, 2015 at 08:45:50PM +02iee80211_ops00, Giedrius Statkevičius wrote:
> Use rt2x00queue_flush_queues() in rt2x00mac_flush() instead of
> reimplementing the same actions the second time. Also, now it flushes
> the rx queue aswell which it didn't before and that makes it completely
> do what it's supposed to do according to struct iee80211_ops: flush()
> must flush all queues.

NACK, RX queue should not be flushed, mac80211 flush is about TX queues
only.

Stanislaw

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

end of thread, other threads:[~2015-03-08 10:37 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-03-07 18:45 [PATCH] rt2x00: use rt2x00queue_flush_queues() instead of implementing the same action Giedrius Statkevičius
2015-03-08 10:37 ` Stanislaw Gruszka

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).