1 --- a/net80211/ieee80211_scan_ap.c
2 +++ b/net80211/ieee80211_scan_ap.c
3 @@ -595,6 +595,14 @@ ap_end(struct ieee80211_scan_state *ss,
7 + /* if we're already running, switch back to the home channel */
8 + if ((vap->iv_state == IEEE80211_S_RUN) &&
9 + (ic->ic_bsschan != IEEE80211_CHAN_ANYC)) {
10 + ic->ic_curchan = ic->ic_bsschan;
11 + ic->ic_set_channel(ic);
15 /* record stats for the channel that was scanned last */
16 ic->ic_set_channel(ic);
17 spin_lock_irqsave(&channel_lock, sflags);
18 @@ -648,6 +656,8 @@ ap_end(struct ieee80211_scan_state *ss,
19 IEEE80211_SCHEDULE_TQUEUE(&as->as_actiontq);
24 SCAN_AP_UNLOCK_IRQ(as);