Date: Tue, 29 May 2007 01:53:25 GMT From: Andrew Thompson <thompsa@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 120531 for review Message-ID: <200705290153.l4T1rPTB023458@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=120531 Change 120531 by thompsa@thompsa_heff on 2007/05/29 01:52:31 - Make sure that net80211 initiates all scan aborts - Remove call to net80211 on IWI_SCAN_ABORTED Affected files ... .. //depot/projects/wifi/sys/dev/iwi/if_iwi.c#28 edit Differences ... ==== //depot/projects/wifi/sys/dev/iwi/if_iwi.c#28 (text+ko) ==== @@ -162,7 +162,6 @@ static int iwi_config(struct iwi_softc *); static int iwi_get_firmware(struct iwi_softc *); static void iwi_put_firmware(struct iwi_softc *); -static void iwi_scanabort(void *, int); static int iwi_scanchan(struct iwi_softc *, unsigned long); static void iwi_scan_start(struct ieee80211com *); static void iwi_scan_end(struct ieee80211com *); @@ -275,7 +274,6 @@ #endif TASK_INIT(&sc->sc_radiontask, 0, iwi_radio_on, sc); TASK_INIT(&sc->sc_radiofftask, 0, iwi_radio_off, sc); - TASK_INIT(&sc->sc_scanaborttask, 0, iwi_scanabort, sc); TASK_INIT(&sc->sc_setwmetask, 0, iwi_wme_setparams, sc); TASK_INIT(&sc->sc_downtask, 0, iwi_down, sc); TASK_INIT(&sc->sc_restarttask, 0, iwi_restart, sc); @@ -969,7 +967,7 @@ taskqueue_enqueue(sc->sc_tq, &sc->sc_downtask); if (ic->ic_state == IEEE80211_S_SCAN && (sc->flags & IWI_FLAG_SCANNING)) - taskqueue_enqueue(sc->sc_tq, &sc->sc_scanaborttask); + ieee80211_cancel_scan(ic); break; case IEEE80211_S_ASSOC: default: @@ -1385,14 +1383,8 @@ sc->sc_scan_timer = 0; sc->flags &= ~IWI_FLAG_SCANNING; - switch (scan->status) { - case IWI_SCAN_COMPLETED: + if (scan->status == IWI_SCAN_COMPLETED) ieee80211_scan_next(ic); - break; - case IWI_SCAN_ABORTED: - ieee80211_cancel_scan(ic); - break; - } break; @@ -2651,19 +2643,6 @@ *st = (*st & 0x0f) | ((scan_type & 0xf) << 4); } -static void -iwi_scanabort(void *arg, int npending) -{ - struct iwi_softc *sc = arg; - IWI_LOCK_DECL; - - IWI_LOCK(sc); - /* NB: make sure we're still scanning */ - if (sc->flags & IWI_FLAG_SCANNING) - iwi_cmd(sc, IWI_CMD_ABORT_SCAN, NULL, 0); - IWI_UNLOCK(sc); -} - /* * Scan on ic_curchan according to ic_scan (essid, active/passive, dwell ...) */ @@ -3451,7 +3430,9 @@ break; case IWI_SCAN_END: sc->flags &= ~IWI_FLAG_CHANNEL_SCAN; - iwi_scanabort(sc, 0); + /* NB: make sure we're still scanning */ + if (sc->flags & IWI_FLAG_SCANNING) + iwi_cmd(sc, IWI_CMD_ABORT_SCAN, NULL, 0); break; case IWI_SCAN_CURCHAN: if (!(sc->flags & IWI_FLAG_CHANNEL_SCAN)) { @@ -3459,12 +3440,9 @@ __func__)); return; } - if (iwi_scanchan(sc, sc->sc_maxdwell)) { - iwi_scanabort(sc, 0); - IWI_UNLOCK(sc); + if (iwi_scanchan(sc, sc->sc_maxdwell)) ieee80211_cancel_scan(ic); - return; - } + break; } done:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200705290153.l4T1rPTB023458>