aboutsummaryrefslogtreecommitdiffstats
path: root/net/mac80211/tx.c
diff options
context:
space:
mode:
authorHelmut Schaa <helmut.schaa@googlemail.com>2009-07-23 06:14:04 -0400
committerJohn W. Linville <linville@tuxdriver.com>2009-07-27 15:24:16 -0400
commitfbe9c429f195111bbf7f1630efa19aee295fd8e7 (patch)
tree80556ac48bfa0e7d60db63e6c71b0bbf58143263 /net/mac80211/tx.c
parent2fb3f028a9a46bd344329766257699b4acb36525 (diff)
mac80211: Replace {sw, hw}_scanning variables with a bitfield
Use a bitfield to store the current scan mode instead of two boolean variables {sw,hw}_scanning. This patch does not introduce functional changes but allows us to enhance the scan flags later (for example for background scanning). Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/tx.c')
-rw-r--r--net/mac80211/tx.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c
index ffd3b10f2696..d7491dc2a65c 100644
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -192,7 +192,7 @@ ieee80211_tx_h_check_assoc(struct ieee80211_tx_data *tx)
192 if (unlikely(info->flags & IEEE80211_TX_CTL_INJECTED)) 192 if (unlikely(info->flags & IEEE80211_TX_CTL_INJECTED))
193 return TX_CONTINUE; 193 return TX_CONTINUE;
194 194
195 if (unlikely(tx->local->sw_scanning) && 195 if (unlikely(test_bit(SCAN_SW_SCANNING, &tx->local->scanning)) &&
196 !ieee80211_is_probe_req(hdr->frame_control) && 196 !ieee80211_is_probe_req(hdr->frame_control) &&
197 !ieee80211_is_nullfunc(hdr->frame_control)) 197 !ieee80211_is_nullfunc(hdr->frame_control))
198 /* 198 /*
@@ -552,7 +552,7 @@ ieee80211_tx_h_rate_ctrl(struct ieee80211_tx_data *tx)
552 * Lets not bother rate control if we're associated and cannot 552 * Lets not bother rate control if we're associated and cannot
553 * talk to the sta. This should not happen. 553 * talk to the sta. This should not happen.
554 */ 554 */
555 if (WARN((tx->local->sw_scanning) && 555 if (WARN(test_bit(SCAN_SW_SCANNING, &tx->local->scanning) &&
556 (sta_flags & WLAN_STA_ASSOC) && 556 (sta_flags & WLAN_STA_ASSOC) &&
557 !rate_usable_index_exists(sband, &tx->sta->sta), 557 !rate_usable_index_exists(sband, &tx->sta->sta),
558 "%s: Dropped data frame as no usable bitrate found while " 558 "%s: Dropped data frame as no usable bitrate found while "
@@ -1411,7 +1411,7 @@ static void ieee80211_xmit(struct ieee80211_sub_if_data *sdata,
1411 1411
1412 if ((local->hw.flags & IEEE80211_HW_PS_NULLFUNC_STACK) && 1412 if ((local->hw.flags & IEEE80211_HW_PS_NULLFUNC_STACK) &&
1413 local->hw.conf.dynamic_ps_timeout > 0 && 1413 local->hw.conf.dynamic_ps_timeout > 0 &&
1414 !local->sw_scanning && !local->hw_scanning && local->ps_sdata) { 1414 !(local->scanning) && local->ps_sdata) {
1415 if (local->hw.conf.flags & IEEE80211_CONF_PS) { 1415 if (local->hw.conf.flags & IEEE80211_CONF_PS) {
1416 ieee80211_stop_queues_by_reason(&local->hw, 1416 ieee80211_stop_queues_by_reason(&local->hw,
1417 IEEE80211_QUEUE_STOP_REASON_PS); 1417 IEEE80211_QUEUE_STOP_REASON_PS);