diff options
| author | Max Laier <mlaier@FreeBSD.org> | 2006-10-13 18:32:43 +0000 |
|---|---|---|
| committer | Max Laier <mlaier@FreeBSD.org> | 2006-10-13 18:32:43 +0000 |
| commit | c7d7b3fa6711d698653276147b562ad40c2215ab (patch) | |
| tree | 897965d63a768fa7c0b822887208ac3bdc950aa0 /sys/dev | |
| parent | 757a0c79bc319156a01e4900729c2e209c01eaf7 (diff) | |
Notes
Diffstat (limited to 'sys/dev')
| -rw-r--r-- | sys/dev/iwi/if_iwi.c | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/sys/dev/iwi/if_iwi.c b/sys/dev/iwi/if_iwi.c index a7c6fa9b6e17..00c85dfa649a 100644 --- a/sys/dev/iwi/if_iwi.c +++ b/sys/dev/iwi/if_iwi.c @@ -2700,7 +2700,7 @@ iwi_scan(struct iwi_softc *sc) struct ieee80211com *ic = &sc->sc_ic; const struct ieee80211_channel *c; struct iwi_scan_ext scan; - int i, ix, start, scan_type; + int i, ix, start, scan_type, error; memset(&scan, 0, sizeof scan); @@ -2711,8 +2711,22 @@ iwi_scan(struct iwi_softc *sc) scan.full_scan_index = htole32(ic->ic_scan.nt_scangen); - scan_type = (ic->ic_des_esslen != 0) ? IWI_SCAN_TYPE_BDIRECTED : - IWI_SCAN_TYPE_BROADCAST; + if (ic->ic_des_esslen != 0) { + scan_type = IWI_SCAN_TYPE_BDIRECTED; +#ifdef IWI_DEBUG + if (iwi_debug > 0) { + printf("Setting desired ESSID to "); + ieee80211_print_essid(ic->ic_des_essid, + ic->ic_des_esslen); + printf("\n"); + } +#endif + error = iwi_cmd(sc, IWI_CMD_SET_ESSID, ic->ic_des_essid, + ic->ic_des_esslen); + if (error != 0) + return error; + } else + scan_type = IWI_SCAN_TYPE_BROADCAST; ix = 0; if (ic->ic_modecaps & IEEE80211_MODE_5GHZ) { |
