mwl8k: minor transmit quiescing rework
authorLennert Buytenhek <buytenh@wantstofly.org>
Thu, 22 Oct 2009 18:19:37 +0000 (20:19 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Wed, 4 Nov 2009 23:44:43 +0000 (18:44 -0500)
commit88de754ad59025eba797e7a8375807755577f450
tree630531ea3a88e8b80ba8c564654af93d7ae0e2b6
parentc2c357ce309221b85fd36e50aade66d01a556cde
mwl8k: minor transmit quiescing rework

Minor changes to the transmit quiescing logic:
- Clarify the locking rules for ->tx_wait: only the holder of fw_mutex
  can wait for the TX path to become idle, but tx_wait itself is read
  and cleared by the TX reclaim tasklet under tx_lock.
- Inline mwl8k_txq_busy() in its callers.
- There's no need to kick the transmitter again in
  mwl8k_tx_wait_empty(), since it will have been kicked when the
  packets currently in the TX ring were added to it.
- If the TX ring didn't drain in time, run mwl8k_scan_tx_ring() after
  reading priv->pending_pkts without dropping tx_lock in between.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/mwl8k.c