aboutsummaryrefslogtreecommitdiffstats
path: root/net/mac80211/rc80211_minstrel_ht.c
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2013-03-16 12:00:26 -0400
committerJohannes Berg <johannes.berg@intel.com>2013-03-18 15:11:58 -0400
commitbc96f24266291c1b967cfa868904731b1bb9a08c (patch)
tree034c3f5bc01f399ceae3d8e6d01c5f6c53189d4a /net/mac80211/rc80211_minstrel_ht.c
parent3e8b1eb21c8b9806928000bf733e5762a64a7f72 (diff)
mac80211/minstrel_ht: avoid useless sampling of high-probability slower rates
Slow rates that have >95% success probability do not need to be monitored continuously. When the channel conditions change rapidly, the slow sampling results are useless anyway. When conditions change slowly, they will be monitored by gradual downgrading of the actively used rates. This patch slightly improves throughput under good conditions. Signed-off-by: Felix Fietkau <nbd@openwrt.org> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/mac80211/rc80211_minstrel_ht.c')
-rw-r--r--net/mac80211/rc80211_minstrel_ht.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/net/mac80211/rc80211_minstrel_ht.c b/net/mac80211/rc80211_minstrel_ht.c
index 90499c421702..0fc9449925ef 100644
--- a/net/mac80211/rc80211_minstrel_ht.c
+++ b/net/mac80211/rc80211_minstrel_ht.c
@@ -653,10 +653,10 @@ minstrel_get_sample_rate(struct minstrel_priv *mp, struct minstrel_ht_sta *mi)
653 if (sample_idx == mi->max_tp_rate) 653 if (sample_idx == mi->max_tp_rate)
654 return -1; 654 return -1;
655 /* 655 /*
656 * When not using MRR, do not sample if the probability is already 656 * Do not sample if the probability is already higher than 95%
657 * higher than 95% to avoid wasting airtime 657 * to avoid wasting airtime.
658 */ 658 */
659 if (!mp->has_mrr && (mr->probability > MINSTREL_FRAC(95, 100))) 659 if (mr->probability > MINSTREL_FRAC(95, 100))
660 return -1; 660 return -1;
661 661
662 /* 662 /*