aboutsummaryrefslogtreecommitdiffstats
path: root/net/mac80211/rx.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/mac80211/rx.c')
-rw-r--r--net/mac80211/rx.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c
index a7263fc476bd..a26aa7f50495 100644
--- a/net/mac80211/rx.c
+++ b/net/mac80211/rx.c
@@ -338,8 +338,14 @@ ieee80211_rx_h_passive_scan(struct ieee80211_txrx_data *rx)
338 struct ieee80211_local *local = rx->local; 338 struct ieee80211_local *local = rx->local;
339 struct sk_buff *skb = rx->skb; 339 struct sk_buff *skb = rx->skb;
340 340
341 if (unlikely(local->sta_scanning != 0)) { 341 if (unlikely(local->sta_hw_scanning))
342 ieee80211_sta_rx_scan(rx->dev, skb, rx->u.rx.status); 342 return ieee80211_sta_rx_scan(rx->dev, skb, rx->u.rx.status);
343
344 if (unlikely(local->sta_sw_scanning)) {
345 /* drop all the other packets during a software scan anyway */
346 if (ieee80211_sta_rx_scan(rx->dev, skb, rx->u.rx.status)
347 != TXRX_QUEUED)
348 dev_kfree_skb(skb);
343 return TXRX_QUEUED; 349 return TXRX_QUEUED;
344 } 350 }
345 351
@@ -1499,7 +1505,7 @@ void __ieee80211_rx(struct ieee80211_hw *hw, struct sk_buff *skb,
1499 goto end; 1505 goto end;
1500 } 1506 }
1501 1507
1502 if (unlikely(local->sta_scanning)) 1508 if (unlikely(local->sta_sw_scanning || local->sta_hw_scanning))
1503 rx.flags |= IEEE80211_TXRXD_RXIN_SCAN; 1509 rx.flags |= IEEE80211_TXRXD_RXIN_SCAN;
1504 1510
1505 if (__ieee80211_invoke_rx_handlers(local, local->rx_pre_handlers, &rx, 1511 if (__ieee80211_invoke_rx_handlers(local, local->rx_pre_handlers, &rx,