aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorSeth Forshee <seth.forshee@canonical.com>2013-02-11 12:21:07 -0500
committerJohannes Berg <johannes.berg@intel.com>2013-02-11 16:52:21 -0500
commit6c17b77b67587b9f9e3070fb89fe98cef3187131 (patch)
tree5e47a8feb14ec822b276c893a9fb3cca93e6bbd0 /include
parentdf15a6c4fa7f77511663d7b5f9134f37ad2e8c92 (diff)
mac80211: Fix tx queue handling during scans
Scans currently work by stopping the netdev tx queues but leaving the mac80211 queues active. This stops the flow of incoming packets while still allowing mac80211 to transmit nullfunc and probe request frames to facilitate scanning. However, the driver may try to wake the mac80211 queues while in this state, which will also wake the netdev queues. To prevent this, add a new queue stop reason, IEEE80211_QUEUE_STOP_REASON_OFFCHANNEL, to be used when stopping the tx queues for off-channel operation. This prevents the netdev queues from waking when a driver wakes the mac80211 queues. This also stops all frames from being transmitted, even those meant to be sent off-channel. Add a new tx control flag, IEEE80211_TX_CTL_OFFCHAN_TX_OK, which allows frames to be transmitted when the queues are stopped only for the off-channel stop reason. Update all locations transmitting off-channel frames to use this flag. Signed-off-by: Seth Forshee <seth.forshee@canonical.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'include')
-rw-r--r--include/net/mac80211.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/net/mac80211.h b/include/net/mac80211.h
index 86ad2c341525..0eaa9092364b 100644
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -399,6 +399,9 @@ struct ieee80211_bss_conf {
399 * @IEEE80211_TX_CTL_RATE_CTRL_PROBE: internal to mac80211, can be 399 * @IEEE80211_TX_CTL_RATE_CTRL_PROBE: internal to mac80211, can be
400 * set by rate control algorithms to indicate probe rate, will 400 * set by rate control algorithms to indicate probe rate, will
401 * be cleared for fragmented frames (except on the last fragment) 401 * be cleared for fragmented frames (except on the last fragment)
402 * @IEEE80211_TX_INTFL_OFFCHAN_TX_OK: Internal to mac80211. Used to indicate
403 * that a frame can be transmitted while the queues are stopped for
404 * off-channel operation.
402 * @IEEE80211_TX_INTFL_NEED_TXPROCESSING: completely internal to mac80211, 405 * @IEEE80211_TX_INTFL_NEED_TXPROCESSING: completely internal to mac80211,
403 * used to indicate that a pending frame requires TX processing before 406 * used to indicate that a pending frame requires TX processing before
404 * it can be sent out. 407 * it can be sent out.
@@ -464,6 +467,7 @@ enum mac80211_tx_control_flags {
464 IEEE80211_TX_STAT_AMPDU = BIT(10), 467 IEEE80211_TX_STAT_AMPDU = BIT(10),
465 IEEE80211_TX_STAT_AMPDU_NO_BACK = BIT(11), 468 IEEE80211_TX_STAT_AMPDU_NO_BACK = BIT(11),
466 IEEE80211_TX_CTL_RATE_CTRL_PROBE = BIT(12), 469 IEEE80211_TX_CTL_RATE_CTRL_PROBE = BIT(12),
470 IEEE80211_TX_INTFL_OFFCHAN_TX_OK = BIT(13),
467 IEEE80211_TX_INTFL_NEED_TXPROCESSING = BIT(14), 471 IEEE80211_TX_INTFL_NEED_TXPROCESSING = BIT(14),
468 IEEE80211_TX_INTFL_RETRIED = BIT(15), 472 IEEE80211_TX_INTFL_RETRIED = BIT(15),
469 IEEE80211_TX_INTFL_DONT_ENCRYPT = BIT(16), 473 IEEE80211_TX_INTFL_DONT_ENCRYPT = BIT(16),