Commit be6050f7 authored by Felix Fietkau's avatar Felix Fietkau Committed by Greg Kroah-Hartman

mac80211: minstrel_ht: fix per-group max throughput rate initialization

[ Upstream commit 56dd918f ]

The group number needs to be multiplied by the number of rates per group
to get the full rate index

Fixes: 5935839a ("mac80211: improve minstrel_ht rate sorting by throughput & probability")
Signed-off-by: default avatarFelix Fietkau <nbd@nbd.name>
Link: https://lore.kernel.org/r/20190820095449.45255-1-nbd@nbd.nameSigned-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent ae0929cf
...@@ -529,7 +529,7 @@ minstrel_ht_update_stats(struct minstrel_priv *mp, struct minstrel_ht_sta *mi) ...@@ -529,7 +529,7 @@ minstrel_ht_update_stats(struct minstrel_priv *mp, struct minstrel_ht_sta *mi)
/* (re)Initialize group rate indexes */ /* (re)Initialize group rate indexes */
for(j = 0; j < MAX_THR_RATES; j++) for(j = 0; j < MAX_THR_RATES; j++)
tmp_group_tp_rate[j] = group; tmp_group_tp_rate[j] = MCS_GROUP_RATES * group;
for (i = 0; i < MCS_GROUP_RATES; i++) { for (i = 0; i < MCS_GROUP_RATES; i++) {
if (!(mi->supported[group] & BIT(i))) if (!(mi->supported[group] & BIT(i)))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment