Skip to contentSkip to conversation

mac80211: skip legacy rate mask handling for VHT rates

PATCH Applied Felix Fietkau 4 participants 4 messages Nov 15, 2014 – Nov 19, 2014 mac80211

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 mac80211: skip legacy rate mask handling for VHT rates

The rate mask code currently assumes that a rate is legacy if IEEE80211_TX_RC_MCS is not set. This might be the cause of bogus VHT rates being reported with minstrel_ht.

---
 net/mac80211/rate.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
net/mac80211/rate.c +1 -1
index 6081329..f6fea67f 100644
@@ -385,7 +385,7 @@ static void rate_idx_match_mask(struct ieee80211_tx_rate *rate,
 			*rate = alt_rate;
 			return;
 		}
-	} else {
+	} else if (!(rate->flags & IEEE80211_TX_RC_VHT_MCS)) {
 		/* handle legacy rates */
 		if (rate_idx_match_legacy_mask(rate, sband->n_bitrates, mask))
 			return;
Signature · 1 line
2.1.2
#1 lore raw
Quoted 14 lines · Felix Fietkau

The rate mask code currently assumes that a rate is legacy if IEEE80211_TX_RC_MCS is not set. This might be the cause of bogus VHT rates being reported with minstrel_ht.

---
 net/mac80211/rate.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
net/mac80211/rate.c +0 -0
index 6081329..f6fea67f 100644

net/mac80211/rate.c static void rate_idx_match_mask(struct ieee80211_tx_rate *rate, · line 391

Quoted 8 lines
net/mac80211/rate.c +1 -1
@@ -385,7 +385,7 @@ static void rate_idx_match_mask(struct ieee80211_tx_rate *rate,
 			*rate = alt_rate;
 			return;
 		}
-	} else {
+	} else if (!(rate->flags & IEEE80211_TX_RC_VHT_MCS)) {
 		/* handle legacy rates */
 		if (rate_idx_match_legacy_mask(rate, sband->n_bitrates, mask))
 			return;

Does it fix things on your side Jouni ?

Karl

#2 lore raw
Quoted 9 lines · Karl Beldan

net/mac80211/rate.c static void rate_idx_match_mask(struct ieee80211_tx_rate *rate, · line 388

Quoted 6 lines · Felix Fietkau

The rate mask code currently assumes that a rate is legacy if IEEE80211_TX_RC_MCS is not set. This might be the cause of bogus VHT rates being reported with minstrel_ht.

net/mac80211/rate.c +1 -1
-	} else {
+	} else if (!(rate->flags & IEEE80211_TX_RC_VHT_MCS)) {

Does it fix things on your side Jouni ?

Yes, it does resolve the nfc_p2p_* test case failures with CONFIG_MAC80211_RC_MINSTREL_VHT=y.

Signature · 1 line
Jouni Malinen                                            PGP id EFC895FA
maintainer Applied
#3 lore raw
In reply to Felix Fietkau
Quoted 3 lines · Felix Fietkau

The rate mask code currently assumes that a rate is legacy if IEEE80211_TX_RC_MCS is not set. This might be the cause of bogus VHT rates being reported with minstrel_ht.

Applied.

johannes