diff options
author | Ming Lei <tom.leiming@gmail.com> | 2010-07-01 11:18:42 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2010-07-02 13:44:39 -0400 |
commit | 009271f9187d61c638bb4f3db9ab172c5065e542 (patch) | |
tree | 66b86ad7c5434db525631b11d907147a397b5ae9 /net/mac80211 | |
parent | 8e67ca7c9266a4f920d70d3a2cbf03a597d28ea7 (diff) |
minstrel_ht: fix updating rate with best probability
The throughput should be considered when updating rate
with best probability.
Signed-off-by: Ming Lei <tom.leiming@gmail.com>
Acked-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211')
-rw-r--r-- | net/mac80211/rc80211_minstrel_ht.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/net/mac80211/rc80211_minstrel_ht.c b/net/mac80211/rc80211_minstrel_ht.c index 52c85036660d..8fba6f4c5145 100644 --- a/net/mac80211/rc80211_minstrel_ht.c +++ b/net/mac80211/rc80211_minstrel_ht.c | |||
@@ -240,6 +240,7 @@ minstrel_ht_update_stats(struct minstrel_priv *mp, struct minstrel_ht_sta *mi) | |||
240 | MINSTREL_FRAC(3, 4)) || mr->probability > cur_prob) { | 240 | MINSTREL_FRAC(3, 4)) || mr->probability > cur_prob) { |
241 | mg->max_prob_rate = index; | 241 | mg->max_prob_rate = index; |
242 | cur_prob = mr->probability; | 242 | cur_prob = mr->probability; |
243 | cur_prob_tp = mr->cur_tp; | ||
243 | } | 244 | } |
244 | 245 | ||
245 | if (mr->cur_tp > cur_tp) { | 246 | if (mr->cur_tp > cur_tp) { |
@@ -275,6 +276,7 @@ minstrel_ht_update_stats(struct minstrel_priv *mp, struct minstrel_ht_sta *mi) | |||
275 | minstrel_mcs_groups[group].streams == 1) { | 276 | minstrel_mcs_groups[group].streams == 1) { |
276 | mi->max_prob_rate = mg->max_prob_rate; | 277 | mi->max_prob_rate = mg->max_prob_rate; |
277 | cur_prob = mr->cur_prob; | 278 | cur_prob = mr->cur_prob; |
279 | cur_prob_tp = mr->cur_tp; | ||
278 | } | 280 | } |
279 | 281 | ||
280 | mr = minstrel_get_ratestats(mi, mg->max_tp_rate); | 282 | mr = minstrel_get_ratestats(mi, mg->max_tp_rate); |