Skip to content

Commit

Permalink
mac80211: Don't scan if BSSID and channel are set manually
Browse files Browse the repository at this point in the history
If you set a fixed BSSID and channel it's not necessary to scan for
neighbors to merge, because you really don't want to merge with it. So
don't do it.

Signed-off-by: Alina Friedrichsen <x-alina@gmx.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
Alina Friedrichsen authored and John W. Linville committed Jan 29, 2009
1 parent 0efcdfd commit 137f9f4
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions net/mac80211/mlme.c
Original file line number Diff line number Diff line change
Expand Up @@ -2009,6 +2009,10 @@ static void ieee80211_sta_merge_ibss(struct ieee80211_sub_if_data *sdata,
if (ieee80211_sta_active_ibss(sdata))
return;

if ((sdata->u.sta.flags & IEEE80211_STA_BSSID_SET) &&
(!(sdata->u.sta.flags & IEEE80211_STA_AUTO_CHANNEL_SEL)))
return;

printk(KERN_DEBUG "%s: No active IBSS STAs - trying to scan for other "
"IBSS networks with same SSID (merge)\n", sdata->dev->name);
ieee80211_request_scan(sdata, ifsta->ssid, ifsta->ssid_len);
Expand Down

0 comments on commit 137f9f4

Please sign in to comment.