Skip to content

Commit

Permalink
[PATCH] Restore channel setting after scan.
Browse files Browse the repository at this point in the history
After a scan, we weren't switching back to the original channel if we
were associated with an AP. So NetworkManager's periodic scans would
disrupt connectivity until the ESSID was manually set again. Fix that.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
David Woodhouse authored and John W. Linville committed Mar 23, 2006
1 parent 9320199 commit 4edac92
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions net/ieee80211/softmac/ieee80211softmac_scan.c
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,13 @@ void ieee80211softmac_scan_finished(struct ieee80211softmac_device *sm)
sm->scanning = 0;
spin_unlock_irqrestore(&sm->lock, flags);

if (sm->associnfo.bssvalid) {
struct ieee80211softmac_network *net;

net = ieee80211softmac_get_network_by_bssid(sm, sm->associnfo.bssid);
if (net)
sm->set_channel(sm->dev, net->channel);
}
ieee80211softmac_call_events(sm, IEEE80211SOFTMAC_EVENT_SCAN_FINISHED, NULL);
}
EXPORT_SYMBOL_GPL(ieee80211softmac_scan_finished);

0 comments on commit 4edac92

Please sign in to comment.