Blame SOURCES/0097-Revert-iwlwifi-rs-fw-enable-STBC-in-he-correctly.patch

deb259
From e440e418dbbee449983773e61107dee566d81da8 Mon Sep 17 00:00:00 2001
deb259
From: Eugene Syromiatnikov <esyr@redhat.com>
deb259
Date: Fri, 6 Sep 2019 15:41:06 +0200
deb259
Subject: [PATCH 5/5] Revert "iwlwifi: rs-fw: enable STBC in he correctly"
deb259
deb259
This reverts commit 3e467b8e4cf4d56244f92b1fb26a25e405e7d3aa.
deb259
---
deb259
 drivers/net/wireless/intel/iwlwifi/fw/api/rs.h | 10 +++-------
deb259
 drivers/net/wireless/intel/iwlwifi/mvm/rs-fw.c | 20 ++++----------------
deb259
 2 files changed, 7 insertions(+), 23 deletions(-)
deb259
deb259
Index: src/drivers/net/wireless/intel/iwlwifi/fw/api/rs.h
deb259
===================================================================
deb259
--- src.orig/drivers/net/wireless/intel/iwlwifi/fw/api/rs.h	2019-09-06 15:42:07.804267670 +0200
deb259
+++ src/drivers/net/wireless/intel/iwlwifi/fw/api/rs.h	2019-09-06 15:42:07.977264927 +0200
deb259
@@ -66,16 +66,12 @@
deb259
 
deb259
 /**
deb259
  * enum iwl_tlc_mng_cfg_flags_enum - options for TLC config flags
deb259
- * @IWL_TLC_MNG_CFG_FLAGS_STBC_MSK: enable STBC. For HE this enables STBC for
deb259
- *				    bandwidths <= 80MHz
deb259
+ * @IWL_TLC_MNG_CFG_FLAGS_STBC_MSK: enable STBC
deb259
  * @IWL_TLC_MNG_CFG_FLAGS_LDPC_MSK: enable LDPC
deb259
- * @IWL_TLC_MNG_CFG_FLAGS_HE_STBC_160MHZ_MSK: enable STBC in HE at 160MHz
deb259
- *					      bandwidth
deb259
  */
deb259
 enum iwl_tlc_mng_cfg_flags {
deb259
-	IWL_TLC_MNG_CFG_FLAGS_STBC_MSK			= BIT(0),
deb259
-	IWL_TLC_MNG_CFG_FLAGS_LDPC_MSK			= BIT(1),
deb259
-	IWL_TLC_MNG_CFG_FLAGS_HE_STBC_160MHZ_MSK	= BIT(2),
deb259
+	IWL_TLC_MNG_CFG_FLAGS_STBC_MSK		= BIT(0),
deb259
+	IWL_TLC_MNG_CFG_FLAGS_LDPC_MSK		= BIT(1),
deb259
 };
deb259
 
deb259
 /**
deb259
Index: src/drivers/net/wireless/intel/iwlwifi/mvm/rs-fw.c
deb259
===================================================================
deb259
--- src.orig/drivers/net/wireless/intel/iwlwifi/mvm/rs-fw.c	2019-09-06 15:42:07.804267670 +0200
deb259
+++ src/drivers/net/wireless/intel/iwlwifi/mvm/rs-fw.c	2019-09-06 15:42:07.977264927 +0200
deb259
@@ -117,26 +117,14 @@
deb259
 {
deb259
 	struct ieee80211_sta_ht_cap *ht_cap = &sta->ht_cap;
deb259
 	struct ieee80211_sta_vht_cap *vht_cap = &sta->vht_cap;
deb259
-	struct ieee80211_sta_he_cap *he_cap = &sta->he_cap;
deb259
 	bool vht_ena = vht_cap && vht_cap->vht_supported;
deb259
 	u16 flags = 0;
deb259
 
deb259
 	if (mvm->cfg->ht_params->stbc &&
deb259
-	    (num_of_ant(iwl_mvm_get_valid_tx_ant(mvm)) > 1)) {
deb259
-		if (he_cap && he_cap->has_he) {
deb259
-			if (he_cap->he_cap_elem.phy_cap_info[2] &
deb259
-			    IEEE80211_HE_PHY_CAP2_STBC_RX_UNDER_80MHZ)
deb259
-				flags |= IWL_TLC_MNG_CFG_FLAGS_STBC_MSK;
deb259
-
deb259
-			if (he_cap->he_cap_elem.phy_cap_info[7] &
deb259
-			    IEEE80211_HE_PHY_CAP7_STBC_RX_ABOVE_80MHZ)
deb259
-				flags |= IWL_TLC_MNG_CFG_FLAGS_HE_STBC_160MHZ_MSK;
deb259
-		} else if ((ht_cap &&
deb259
-			    (ht_cap->cap & IEEE80211_HT_CAP_RX_STBC)) ||
deb259
-			   (vht_ena &&
deb259
-			    (vht_cap->cap & IEEE80211_VHT_CAP_RXSTBC_MASK)))
deb259
-			flags |= IWL_TLC_MNG_CFG_FLAGS_STBC_MSK;
deb259
-	}
deb259
+	    (num_of_ant(iwl_mvm_get_valid_tx_ant(mvm)) > 1) &&
deb259
+	    ((ht_cap && (ht_cap->cap & IEEE80211_HT_CAP_RX_STBC)) ||
deb259
+	     (vht_ena && (vht_cap->cap & IEEE80211_VHT_CAP_RXSTBC_MASK))))
deb259
+		flags |= IWL_TLC_MNG_CFG_FLAGS_STBC_MSK;
deb259
 
deb259
 	if (mvm->cfg->ht_params->ldpc &&
deb259
 	    ((ht_cap && (ht_cap->cap & IEEE80211_HT_CAP_LDPC_CODING)) ||