-/* $OpenBSD: if_iwm.c,v 1.58 2015/10/16 10:29:55 stsp Exp $ */
+/* $OpenBSD: if_iwm.c,v 1.59 2015/10/16 12:17:38 stsp Exp $ */
/*
* Copyright (c) 2014 genua mbh <info@genua.de>
* to allocate the time events. Warn on it, but maybe we
* should try to send the command again with different params.
*/
- sc->sc_scanband = 0;
ret = EIO;
}
return ret;
if ((error = iwm_mvm_scan_request(sc, IEEE80211_CHAN_2GHZ,
ic->ic_des_esslen != 0,
ic->ic_des_essid, ic->ic_des_esslen)) != 0) {
- printf("%s: could not initiate scan\n", DEVNAME(sc));
+ printf("%s: could not initiate 2 GHz scan\n",
+ DEVNAME(sc));
+ sc->sc_scanband = 0;
return;
}
ic->ic_state = nstate;
if ((error = iwm_mvm_scan_request(sc,
IEEE80211_CHAN_5GHZ, ic->ic_des_esslen != 0,
ic->ic_des_essid, ic->ic_des_esslen)) != 0) {
- printf("%s: could not initiate scan\n", DEVNAME(sc));
+ printf("%s: could not initiate 5 GHz scan\n",
+ DEVNAME(sc));
done = 1;
}
} else {
}
if (done) {
- if (!sc->sc_scanband) {
- ic->ic_scan_lock = IEEE80211_SCAN_UNLOCKED;
- } else {
- ieee80211_end_scan(&ic->ic_if);
- }
+ ieee80211_end_scan(&ic->ic_if);
sc->sc_scanband = 0;
}
}