mac80211: fix sending probe requests in client mode, fixes connecting to hidden netwo...
authorFelix Fietkau <nbd@openwrt.org>
Tue, 26 Feb 2013 21:52:59 +0000 (21:52 +0000)
committerFelix Fietkau <nbd@openwrt.org>
Tue, 26 Feb 2013 21:52:59 +0000 (21:52 +0000)
SVN-Revision: 35819

package/mac80211/patches/300-pending_work.patch
package/mac80211/patches/540-mac80211_optimize_mcs_rate_mask.patch

index 1bc32a0671829e3ef1cafc0ffc86c643f418901a..508a674c5a68d078c9e7c839844a6e3b8849f9fb 100644 (file)
        WLAN_STA_BLOCK_BA,
 --- a/net/mac80211/tx.c
 +++ b/net/mac80211/tx.c
-@@ -1848,9 +1848,24 @@ netdev_tx_t ieee80211_subif_start_xmit(s
+@@ -1231,34 +1231,40 @@ static bool ieee80211_tx_frags(struct ie
+               if (local->queue_stop_reasons[q] ||
+                   (!txpending && !skb_queue_empty(&local->pending[q]))) {
+                       if (unlikely(info->flags &
+-                                      IEEE80211_TX_INTFL_OFFCHAN_TX_OK &&
+-                                   local->queue_stop_reasons[q] &
+-                                      ~BIT(IEEE80211_QUEUE_STOP_REASON_OFFCHANNEL))) {
++                                   IEEE80211_TX_INTFL_OFFCHAN_TX_OK)) {
++                              if (local->queue_stop_reasons[q] &
++                                  ~BIT(IEEE80211_QUEUE_STOP_REASON_OFFCHANNEL)) {
++                                      /*
++                                       * Drop off-channel frames if queues
++                                       * are stopped for any reason other
++                                       * than off-channel operation. Never
++                                       * queue them.
++                                       */
++                                      spin_unlock_irqrestore(
++                                              &local->queue_stop_reason_lock,
++                                              flags);
++                                      ieee80211_purge_tx_queue(&local->hw,
++                                                               skbs);
++                                      return true;
++                              }
++                      } else {
++
+                               /*
+-                               * Drop off-channel frames if queues are stopped
+-                               * for any reason other than off-channel
+-                               * operation. Never queue them.
++                               * Since queue is stopped, queue up frames for
++                               * later transmission from the tx-pending
++                               * tasklet when the queue is woken again.
+                                */
+-                              spin_unlock_irqrestore(
+-                                      &local->queue_stop_reason_lock, flags);
+-                              ieee80211_purge_tx_queue(&local->hw, skbs);
+-                              return true;
++                              if (txpending)
++                                      skb_queue_splice_init(skbs,
++                                                            &local->pending[q]);
++                              else
++                                      skb_queue_splice_tail_init(skbs,
++                                                                 &local->pending[q]);
++
++                              spin_unlock_irqrestore(&local->queue_stop_reason_lock,
++                                                     flags);
++                              return false;
+                       }
+-
+-                      /*
+-                       * Since queue is stopped, queue up frames for later
+-                       * transmission from the tx-pending tasklet when the
+-                       * queue is woken again.
+-                       */
+-                      if (txpending)
+-                              skb_queue_splice_init(skbs, &local->pending[q]);
+-                      else
+-                              skb_queue_splice_tail_init(skbs,
+-                                                         &local->pending[q]);
+-
+-                      spin_unlock_irqrestore(&local->queue_stop_reason_lock,
+-                                             flags);
+-                      return false;
+               }
+               spin_unlock_irqrestore(&local->queue_stop_reason_lock, flags);
+@@ -1848,9 +1854,24 @@ netdev_tx_t ieee80211_subif_start_xmit(s
                }
  
                if (!is_multicast_ether_addr(skb->data)) {
index 370963933446529b41cde621779fe0d50c88b725..347c9201356cb052ef765346d3525c8db5d58c21 100644 (file)
@@ -69,7 +69,7 @@
        txrc.bss = (tx->sdata->vif.type == NL80211_IFTYPE_AP ||
                    tx->sdata->vif.type == NL80211_IFTYPE_MESH_POINT ||
                    tx->sdata->vif.type == NL80211_IFTYPE_ADHOC);
-@@ -2505,8 +2507,6 @@ struct sk_buff *ieee80211_beacon_get_tim
+@@ -2511,8 +2513,6 @@ struct sk_buff *ieee80211_beacon_get_tim
                txrc.max_rate_idx = -1;
        else
                txrc.max_rate_idx = fls(txrc.rate_idx_mask) - 1;