-/* $OpenBSD: ieee80211_rssadapt.c,v 1.6 2007/06/16 13:17:05 damien Exp $ */
+/* $OpenBSD: ieee80211_rssadapt.c,v 1.7 2008/09/01 20:00:19 damien Exp $ */
/* $NetBSD: ieee80211_rssadapt.c,v 1.7 2004/05/25 04:33:59 dyoung Exp $ */
/*-
#define RSSADAPT_PRINTF(X)
#endif
-static struct ieee80211_rssadapt_expavgctl master_expavgctl = {
- rc_decay_denom : 16,
- rc_decay_old : 15,
- rc_thresh_denom : 8,
- rc_thresh_old : 4,
- rc_avgrssi_denom : 8,
- rc_avgrssi_old : 4
+static const struct ieee80211_rssadapt_expavgctl master_expavgctl = {
+ .rc_decay_denom = 16,
+ .rc_decay_old = 15,
+ .rc_thresh_denom = 8,
+ .rc_thresh_old = 4,
+ .rc_avgrssi_denom = 8,
+ .rc_avgrssi_old = 4
};
int
rate = (rs->rs_rates[id->id_rateidx + 1] & IEEE80211_RATE_VAL);
RSSADAPT_PRINTF(("%s: threshold[%d, %d.%d] decay %d ",
- ic->ic_if.if_xname,
- IEEE80211_RSSADAPT_BKT0 << (IEEE80211_RSSADAPT_BKTPOWER* i),
+ ic->ic_if.if_xname, IEEE80211_RSSADAPT_BKT0 <<
+ (IEEE80211_RSSADAPT_BKTPOWER * i),
rate / 2, rate * 5 % 10, (*thrs)[id->id_rateidx + 1]));
oldthr = (*thrs)[id->id_rateidx + 1];
if ((*thrs)[id->id_rateidx] == 0)