mac80211: merge upstream patch to suppress unnecessary ad-hoc mode scan with fixed...
authorFelix Fietkau <nbd@openwrt.org>
Tue, 13 Aug 2013 10:35:04 +0000 (10:35 +0000)
committerFelix Fietkau <nbd@openwrt.org>
Tue, 13 Aug 2013 10:35:04 +0000 (10:35 +0000)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 37764

package/kernel/mac80211/patches/300-pending_work.patch

index 55449db..4ec4423 100644 (file)
        if (len > size)
                len = size;
  
+--- a/net/mac80211/ibss.c
++++ b/net/mac80211/ibss.c
+@@ -792,6 +792,17 @@ static void ieee80211_sta_find_ibss(stru
+               return;
+       }
++      /* if a fixed bssid and a fixed freq have been provided create the IBSS
++       * directly and do not waste time scanning
++       */
++      if (ifibss->fixed_bssid && ifibss->fixed_channel) {
++              sdata_info(sdata, "Created IBSS using preconfigured BSSID %pM\n",
++                         bssid);
++              ieee80211_sta_create_ibss(sdata);
++              return;
++      }
++
++
+       ibss_dbg(sdata, "sta_find_ibss: did not try to join ibss\n");
+       /* Selected IBSS not found in current scan results - try to scan */