Lines Matching +full:fixed +full:- +full:rate

1 /*-
2 * SPDX-License-Identifier: BSD-3-Clause
17 * 3. Neither the names of the above-listed copyright holders nor the names
45 /* per-device state */
53 int min_switch; /* min time between rate changes */
54 int min_good_pct; /* min good percentage for a rate to be considered */
56 #define ATH_SOFTC_SAMPLE(sc) ((struct sample_softc *)sc->sc_rc)
70 uint8_t t0, r0; /* series 0: tries, rate code */
71 uint8_t t1, r1; /* series 1: tries, rate code */
72 uint8_t t2, r2; /* series 2: tries, rate code */
73 uint8_t t3, r3; /* series 3: tries, rate code */
89 /* per-node state */
91 int static_rix; /* rate index of fixed tx rate */
93 uint64_t ratemask; /* bit mask of valid rate indices */
115 #define IS_RATE_DEFINED(sn, rix) (((uint64_t) (sn)->ratemask & (1ULL<<((uint64_t) rix))) != 0)
135 const HAL_RATE_TABLE *rt = sc->sc_currates; in calc_usecs_unicast_packet()
136 struct ieee80211com *ic = &sc->sc_ic; in calc_usecs_unicast_packet()
147 KASSERT(rt != NULL, ("no rate table, mode %u", sc->sc_curmode)); in calc_usecs_unicast_packet()
149 if (rix >= rt->rateCount) { in calc_usecs_unicast_packet()
151 rix, rt->rateCount, sc->sc_curmode); in calc_usecs_unicast_packet()
154 cix = rt->info[rix].controlRate; in calc_usecs_unicast_packet()
156 * XXX getting mac/phy level timings should be fixed for turbo in calc_usecs_unicast_packet()
160 switch (rt->info[rix].phy) { in calc_usecs_unicast_packet()
187 if ((ic->ic_flags & IEEE80211_F_USEPROT) && in calc_usecs_unicast_packet()
188 rt->info[rix].phy == IEEE80211_T_OFDM) { in calc_usecs_unicast_packet()
189 if (ic->ic_protmode == IEEE80211_PROT_RTSCTS) in calc_usecs_unicast_packet()
191 else if (ic->ic_protmode == IEEE80211_PROT_CTSONLY) in calc_usecs_unicast_packet()
194 cix = rt->info[sc->sc_protrix].controlRate; in calc_usecs_unicast_packet()
197 if (0 /*length > ic->ic_rtsthreshold */) { in calc_usecs_unicast_packet()
206 KASSERT(cix < rt->rateCount, in calc_usecs_unicast_packet()
207 ("bogus cix %d, max %u, mode %u\n", cix, rt->rateCount, in calc_usecs_unicast_packet()
208 sc->sc_curmode)); in calc_usecs_unicast_packet()
210 ctsrate = rt->info[cix].rateCode | rt->info[cix].shortPreamble; in calc_usecs_unicast_packet()
212 ctsduration += rt->info[cix].spAckDuration; in calc_usecs_unicast_packet()
215 ctsduration += ath_hal_pkt_txtime(sc->sc_ah, rt, length, rix, in calc_usecs_unicast_packet()
219 ctsduration += rt->info[cix].spAckDuration; in calc_usecs_unicast_packet()
226 tt += (long_retries+1)*ath_hal_pkt_txtime(sc->sc_ah, rt, length, rix, in calc_usecs_unicast_packet()
229 tt += (long_retries+1)*(t_sifs + rt->info[rix].spAckDuration); in calc_usecs_unicast_packet()