diff options
author | onoe <onoe@FreeBSD.org> | 2001-06-26 13:10:30 +0000 |
---|---|---|
committer | onoe <onoe@FreeBSD.org> | 2001-06-26 13:10:30 +0000 |
commit | ab4f0f1d6bef4c6e0a07b1d0882d2c670f4029cc (patch) | |
tree | 7d1288b04a8cfbaf750b55db85d35a6d2d0d36d7 /sys/dev/awi | |
parent | 67840ab392c1c9a425abbd8149fb93e1986b4bcc (diff) | |
download | FreeBSD-src-ab4f0f1d6bef4c6e0a07b1d0882d2c670f4029cc.zip FreeBSD-src-ab4f0f1d6bef4c6e0a07b1d0882d2c670f4029cc.tar.gz |
Fix capability information in association request to reflect ESS/IBSS mode.
This fix is required to interoperate with Cisco's access point.
Obtained from: NetBSD current
Diffstat (limited to 'sys/dev/awi')
-rw-r--r-- | sys/dev/awi/awi.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/sys/dev/awi/awi.c b/sys/dev/awi/awi.c index a2f1162..17c58ba 100644 --- a/sys/dev/awi/awi.c +++ b/sys/dev/awi/awi.c @@ -2365,7 +2365,7 @@ awi_send_asreq(sc, reassoc) struct ifnet *ifp = sc->sc_ifp; struct mbuf *m; struct ieee80211_frame *wh; - u_int16_t lintval; + u_int16_t capinfo, lintval; u_int8_t *asreq; MGETHDR(m, M_DONTWAIT, MT_DATA); @@ -2393,12 +2393,16 @@ awi_send_asreq(sc, reassoc) asreq = (u_int8_t *)&wh[1]; /* capability info */ - if (sc->sc_wep_algo == NULL) - LE_WRITE_2(asreq, IEEE80211_CAPINFO_CF_POLLABLE); + capinfo = IEEE80211_CAPINFO_CF_POLLABLE; + if (sc->sc_mib_local.Network_Mode) + capinfo |= IEEE80211_CAPINFO_ESS; else - LE_WRITE_2(asreq, - IEEE80211_CAPINFO_CF_POLLABLE | IEEE80211_CAPINFO_PRIVACY); + capinfo |= IEEE80211_CAPINFO_IBSS; + if (sc->sc_wep_algo != NULL) + capinfo |= IEEE80211_CAPINFO_PRIVACY; + LE_WRITE_2(asreq, capinfo); asreq += 2; + /* listen interval */ lintval = LE_READ_2(&sc->sc_mib_mgt.aListen_Interval); LE_WRITE_2(asreq, lintval); |