aboutsummaryrefslogtreecommitdiffstats
path: root/net/mac80211
diff options
context:
space:
mode:
authorAntonio Quartulli <antonio@open-mesh.com>2013-08-09 12:58:32 -0400
committerJohannes Berg <johannes.berg@intel.com>2013-08-12 12:08:34 -0400
commitd8eb741eb374804e864751c7f3919ae50321d831 (patch)
tree63eee4920e2204e302b7bb93b709f74753d77ce7 /net/mac80211
parent52981cd79461e47fe683febfcbd3d380c72b1c6c (diff)
mac80211: ibss - do not scan if not needed when creating an IBSS
In some cases mac80211 will scan before creating an IBSS even if bssid and frequency have been forced by the user. This is not needed and leads only to a delay in the IBSS establishment phase. Immediately create the cell if both bssid and frequency (and fixed_freq is set) have been specified. Signed-off-by: Antonio Quartulli <antonio@open-mesh.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/mac80211')
-rw-r--r--net/mac80211/ibss.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/net/mac80211/ibss.c b/net/mac80211/ibss.c
index e08387cdc8fd..79e294e9b5cc 100644
--- a/net/mac80211/ibss.c
+++ b/net/mac80211/ibss.c
@@ -891,6 +891,17 @@ static void ieee80211_sta_find_ibss(struct ieee80211_sub_if_data *sdata)
891 return; 891 return;
892 } 892 }
893 893
894 /* if a fixed bssid and a fixed freq have been provided create the IBSS
895 * directly and do not waste time scanning
896 */
897 if (ifibss->fixed_bssid && ifibss->fixed_channel) {
898 sdata_info(sdata, "Created IBSS using preconfigured BSSID %pM\n",
899 bssid);
900 ieee80211_sta_create_ibss(sdata);
901 return;
902 }
903
904
894 ibss_dbg(sdata, "sta_find_ibss: did not try to join ibss\n"); 905 ibss_dbg(sdata, "sta_find_ibss: did not try to join ibss\n");
895 906
896 /* Selected IBSS not found in current scan results - try to scan */ 907 /* Selected IBSS not found in current scan results - try to scan */