Lines Matching refs:ra

81 ieee80211_rssadapt_choose(struct ieee80211_rssadapt *ra,  in ieee80211_rssadapt_choose()  argument
99 thrs = &ra->ra_rate_thresh[thridx]; in ieee80211_rssadapt_choose()
117 if ((*thrs)[i] < ra->ra_avg_rssi) in ieee80211_rssadapt_choose()
128 (*thrs)[rateidx], ra->ra_avg_rssi); in ieee80211_rssadapt_choose()
135 ieee80211_rssadapt_updatestats(struct ieee80211_rssadapt *ra) in ieee80211_rssadapt_updatestats() argument
139 ra->ra_pktrate = in ieee80211_rssadapt_updatestats()
140 (ra->ra_pktrate + 10 * (ra->ra_nfail + ra->ra_nok)) / 2; in ieee80211_rssadapt_updatestats()
141 ra->ra_nfail = ra->ra_nok = 0; in ieee80211_rssadapt_updatestats()
146 interval = MAX(100000, 10000000 / MAX(1, 10 * ra->ra_pktrate)); in ieee80211_rssadapt_updatestats()
147 ra->ra_raise_interval.tv_sec = interval / (1000 * 1000); in ieee80211_rssadapt_updatestats()
148 ra->ra_raise_interval.tv_usec = interval % (1000 * 1000); in ieee80211_rssadapt_updatestats()
153 const struct ieee80211_node *ni, struct ieee80211_rssadapt *ra, int rssi) in ieee80211_rssadapt_input() argument
156 int last_avg_rssi = ra->ra_avg_rssi; in ieee80211_rssadapt_input()
159 ra->ra_avg_rssi = interpolate(master_expavgctl.rc_avgrssi, in ieee80211_rssadapt_input()
160 ra->ra_avg_rssi, (rssi << 8)); in ieee80211_rssadapt_input()
164 rssi, last_avg_rssi, ra->ra_avg_rssi)); in ieee80211_rssadapt_input()
175 const struct ieee80211_node *ni, struct ieee80211_rssadapt *ra, in ieee80211_rssadapt_lower_rate() argument
182 ra->ra_nfail++; in ieee80211_rssadapt_lower_rate()
200 last_thr = ra->ra_rate_thresh[thridx][id->id_rateidx]; in ieee80211_rssadapt_lower_rate()
201 ra->ra_rate_thresh[thridx][id->id_rateidx] = in ieee80211_rssadapt_lower_rate()
210 last_thr, ra->ra_rate_thresh[thridx][id->id_rateidx])); in ieee80211_rssadapt_lower_rate()
215 struct ieee80211_rssadapt *ra, const struct ieee80211_rssdesc *id) in ieee80211_rssadapt_raise_rate() argument
225 ra->ra_nok++; in ieee80211_rssadapt_raise_rate()
227 if (!ratecheck(&ra->ra_last_raise, &ra->ra_raise_interval)) in ieee80211_rssadapt_raise_rate()
233 thrs = &ra->ra_rate_thresh[i]; in ieee80211_rssadapt_raise_rate()
248 newthr = ra->ra_avg_rssi; in ieee80211_rssadapt_raise_rate()
267 rate * 5 % 10, ra->ra_rate_thresh[i][j]); in ieee80211_rssadapt_raise_rate()