Date: Mon, 27 Oct 2008 18:02:47 +0000 (UTC) From: Sam Leffler <sam@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r184365 - head/sys/dev/ath Message-ID: <200810271802.m9RI2lIb047915@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: sam Date: Mon Oct 27 18:02:47 2008 New Revision: 184365 URL: http://svn.freebsd.org/changeset/base/184365 Log: fix handling of HT rates; these overlap legacy rates and need to be marked as MCS in the inverse mapping table Modified: head/sys/dev/ath/if_ath.c Modified: head/sys/dev/ath/if_ath.c ============================================================================== --- head/sys/dev/ath/if_ath.c Mon Oct 27 18:00:43 2008 (r184364) +++ head/sys/dev/ath/if_ath.c Mon Oct 27 18:02:47 2008 (r184365) @@ -6225,8 +6225,13 @@ ath_setcurmode(struct ath_softc *sc, enu memset(sc->sc_rixmap, 0xff, sizeof(sc->sc_rixmap)); rt = sc->sc_rates[mode]; KASSERT(rt != NULL, ("no h/w rate set for phy mode %u", mode)); - for (i = 0; i < rt->rateCount; i++) - sc->sc_rixmap[rt->info[i].dot11Rate & IEEE80211_RATE_VAL] = i; + for (i = 0; i < rt->rateCount; i++) { + uint8_t ieeerate = rt->info[i].dot11Rate & IEEE80211_RATE_VAL; + if (rt->info[i].phy != IEEE80211_T_HT) + sc->sc_rixmap[ieeerate] = i; + else + sc->sc_rixmap[ieeerate | IEEE80211_RATE_MCS] = i; + } memset(sc->sc_hwmap, 0, sizeof(sc->sc_hwmap)); for (i = 0; i < 32; i++) { u_int8_t ix = rt->rateCodeToIndex[i];
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200810271802.m9RI2lIb047915>