mac80211: Add TXQ scheduling API
authorToke Høiland-Jørgensen <toke@toke.dk>
Tue, 31 Oct 2017 11:27:45 +0000 (12:27 +0100)
committerJohannes Berg <johannes.berg@intel.com>
Mon, 11 Dec 2017 11:37:51 +0000 (12:37 +0100)
commite937b8da5a591f141fe41aa48a2e898df9888c95
tree7a7d3eb5261a47160fef831203a0c90fca6bee8d
parent9de18d8186cb070d22ed67a3f75a2ef5fbf3ef6f
mac80211: Add TXQ scheduling API

This adds an API to mac80211 to handle scheduling of TXQs and changes the
interface between driver and mac80211 for TXQ handling as follows:

- The wake_tx_queue callback interface no longer includes the TXQ. Instead,
  the driver is expected to retrieve that from ieee80211_next_txq()

- Two new mac80211 functions are added: ieee80211_next_txq() and
  ieee80211_schedule_txq(). The former returns the next TXQ that should be
  scheduled, and is how the driver gets a queue to pull packets from. The
  latter is called internally by mac80211 to start scheduling a queue, and
  the driver is supposed to call it to re-schedule the TXQ after it is
  finished pulling packets from it (unless the queue emptied).

The ath9k and ath10k drivers are changed to use the new API.

Signed-off-by: Toke Høiland-Jørgensen <toke@toke.dk>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
15 files changed:
drivers/net/wireless/ath/ath10k/core.c
drivers/net/wireless/ath/ath10k/core.h
drivers/net/wireless/ath/ath10k/mac.c
drivers/net/wireless/ath/ath9k/ath9k.h
drivers/net/wireless/ath/ath9k/main.c
drivers/net/wireless/ath/ath9k/recv.c
drivers/net/wireless/ath/ath9k/xmit.c
include/net/mac80211.h
net/mac80211/agg-tx.c
net/mac80211/driver-ops.h
net/mac80211/ieee80211_i.h
net/mac80211/main.c
net/mac80211/sta_info.c
net/mac80211/trace.h
net/mac80211/tx.c