aboutsummaryrefslogtreecommitdiffstats
path: root/package/kernel/mac80211
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@nbd.name>2021-01-26 16:46:19 +0100
committerFelix Fietkau <nbd@nbd.name>2021-01-26 16:46:45 +0100
commit56c20f0a5ab037ba7dee71ce3d7e05197b2cccf7 (patch)
treeba9f4b2b37ae5cf0140c1b6fa60d4cc98a9b50d6 /package/kernel/mac80211
parent1fdbb8779aab8d64263ea4f5302175bdedfb7bfe (diff)
downloadupstream-56c20f0a5ab037ba7dee71ce3d7e05197b2cccf7.tar.gz
upstream-56c20f0a5ab037ba7dee71ce3d7e05197b2cccf7.tar.bz2
upstream-56c20f0a5ab037ba7dee71ce3d7e05197b2cccf7.zip
mac80211: minstrel_ht: fix regression in the max_prob_rate fix
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'package/kernel/mac80211')
-rw-r--r--package/kernel/mac80211/patches/subsys/352-mac80211-minstrel_ht-fix-regression-in-the-max_prob_.patch23
1 files changed, 23 insertions, 0 deletions
diff --git a/package/kernel/mac80211/patches/subsys/352-mac80211-minstrel_ht-fix-regression-in-the-max_prob_.patch b/package/kernel/mac80211/patches/subsys/352-mac80211-minstrel_ht-fix-regression-in-the-max_prob_.patch
new file mode 100644
index 0000000000..a366a921d4
--- /dev/null
+++ b/package/kernel/mac80211/patches/subsys/352-mac80211-minstrel_ht-fix-regression-in-the-max_prob_.patch
@@ -0,0 +1,23 @@
+From: Felix Fietkau <nbd@nbd.name>
+Date: Tue, 26 Jan 2021 16:40:52 +0100
+Subject: [PATCH] mac80211: minstrel_ht: fix regression in the max_prob_rate
+ fix
+
+Since mi->max_prob_rate is overwritten after the loop that calls
+minstrel_ht_set_best_prob_rate, the new best rate needs to be written to *dest
+
+Fixes: a7fca4e4037f ("mac80211: minstrel_ht: fix max probability rate selection")
+Signed-off-by: Felix Fietkau <nbd@nbd.name>
+---
+
+--- a/net/mac80211/rc80211_minstrel_ht.c
++++ b/net/mac80211/rc80211_minstrel_ht.c
+@@ -545,7 +545,7 @@ minstrel_ht_set_best_prob_rate(struct mi
+ cur_tp_avg = minstrel_ht_get_tp_avg(mi, cur_group, cur_idx,
+ mrs->prob_avg);
+ if (cur_tp_avg > tmp_tp_avg)
+- mi->max_prob_rate = index;
++ *dest = index;
+
+ max_gpr_tp_avg = minstrel_ht_get_tp_avg(mi, max_gpr_group,
+ max_gpr_idx,