373-mac80211-minstrel-fix-using-short-preamble-CCK-rates.patch 1.3 KB

123456789101112131415161718192021222324252627282930313233
  1. From: Felix Fietkau <[email protected]>
  2. Date: Sat, 10 Feb 2018 13:43:07 +0100
  3. Subject: [PATCH] mac80211: minstrel: fix using short preamble CCK rates on
  4. HT clients
  5. mi->supported[MINSTREL_CCK_GROUP] needs to be updated
  6. Fixes: 782dda00ab8e ("mac80211: minstrel_ht: move short preamble check out of get_rate")
  7. Signed-off-by: Felix Fietkau <[email protected]>
  8. ---
  9. Index: backports-v4.18-rc7/net/mac80211/rc80211_minstrel_ht.c
  10. ===================================================================
  11. --- backports-v4.18-rc7.orig/net/mac80211/rc80211_minstrel_ht.c
  12. +++ backports-v4.18-rc7/net/mac80211/rc80211_minstrel_ht.c
  13. @@ -1135,7 +1135,6 @@ minstrel_ht_update_caps(void *priv, stru
  14. struct ieee80211_mcs_info *mcs = &sta->ht_cap.mcs;
  15. u16 ht_cap = sta->ht_cap.cap;
  16. struct ieee80211_sta_vht_cap *vht_cap = &sta->vht_cap;
  17. - struct sta_info *sinfo = container_of(sta, struct sta_info, sta);
  18. int use_vht;
  19. int n_supported = 0;
  20. int ack_dur;
  21. @@ -1267,8 +1266,7 @@ minstrel_ht_update_caps(void *priv, stru
  22. if (!n_supported)
  23. goto use_legacy;
  24. - if (test_sta_flag(sinfo, WLAN_STA_SHORT_PREAMBLE))
  25. - mi->cck_supported_short |= mi->cck_supported_short << 4;
  26. + mi->supported[MINSTREL_CCK_GROUP] |= mi->cck_supported_short << 4;
  27. /* create an initial rate table with the lowest supported rates */
  28. minstrel_ht_update_stats(mp, mi);