OSDN Git Service

ath9k: clean up the code that wakes the mac80211 queues
authorFelix Fietkau <nbd@openwrt.org>
Mon, 24 Jan 2011 18:23:14 +0000 (19:23 +0100)
committerJohn W. Linville <linville@tuxdriver.com>
Fri, 28 Jan 2011 20:39:40 +0000 (15:39 -0500)
commit92460412367c00e97f99babdb898d0930ce604fc
tree590b628b5c55ab6aae1f812854e903b51215d27a
parentcbdbc5eb542da242bfa3cfe18e7828d21c670969
ath9k: clean up the code that wakes the mac80211 queues

Instead of spreading ath_wake_mac80211_queue() calls over multiple places
in the tx path that process the tx queue for completion, call it only
where the pending frames counter gets decremented, eliminating some
redundant checks.
To prevent queue draining from waking the queues prematurely (e.g. during
a hardware reset), reset the queue stop state when draining all queues,
as the caller in main.c will run ieee80211_wake_queues(hw) anyway.

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ath/ath9k/main.c
drivers/net/wireless/ath/ath9k/xmit.c