]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
iwlwifi: mvm: always init rs_fw with 20MHz bandwidth rates
authorNaftali Goldstein <naftali.goldstein@intel.com>
Thu, 10 May 2018 17:32:36 +0000 (20:32 +0300)
committerLuca Coelho <luciano.coelho@intel.com>
Fri, 31 Aug 2018 08:38:38 +0000 (11:38 +0300)
As with the non-offloaded rs case, during assoc on the ap side the phy
context is set to 20MHz until authorization of a client that supports
wider channel-widths. Support this by sending the initial
tlc_config_cmd with max supported channel width of 20MHz until
authorization succeeds.

Fixes: 6b7a5aea71b3 ("iwlwifi: mvm: always init rs with 20mhz bandwidth rates")
Signed-off-by: Naftali Goldstein <naftali.goldstein@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
drivers/net/wireless/intel/iwlwifi/mvm/rs-fw.c
drivers/net/wireless/intel/iwlwifi/mvm/rs.c
drivers/net/wireless/intel/iwlwifi/mvm/rs.h

index 8169d1450b3b9b3954ff45e4b32d44fd3062788b..1a7a158890cbf6bf5f5ccaf62f23a81a5eddba83 100644 (file)
@@ -311,7 +311,7 @@ void iwl_mvm_tlc_update_notif(struct iwl_mvm *mvm,
 }
 
 void rs_fw_rate_init(struct iwl_mvm *mvm, struct ieee80211_sta *sta,
-                    enum nl80211_band band)
+                    enum nl80211_band band, bool update)
 {
        struct ieee80211_hw *hw = mvm->hw;
        struct iwl_mvm_sta *mvmsta = iwl_mvm_sta_from_mac80211(sta);
@@ -320,7 +320,8 @@ void rs_fw_rate_init(struct iwl_mvm *mvm, struct ieee80211_sta *sta,
        struct ieee80211_supported_band *sband;
        struct iwl_tlc_config_cmd cfg_cmd = {
                .sta_id = mvmsta->sta_id,
-               .max_ch_width = rs_fw_bw_from_sta_bw(sta),
+               .max_ch_width = update ?
+                       rs_fw_bw_from_sta_bw(sta) : RATE_MCS_CHAN_WIDTH_20,
                .flags = cpu_to_le16(rs_fw_set_config_flags(mvm, sta)),
                .chains = rs_fw_set_active_chains(iwl_mvm_get_valid_tx_ant(mvm)),
                .max_mpdu_len = cpu_to_le16(sta->max_amsdu_len),
index d3e389a99a8ad9304dec23c1bae0d0cca82f358e..c3282f1d77bac855b87a2d9356bd37b8c5908380 100644 (file)
@@ -4099,7 +4099,7 @@ void iwl_mvm_rs_rate_init(struct iwl_mvm *mvm, struct ieee80211_sta *sta,
                          enum nl80211_band band, bool update)
 {
        if (iwl_mvm_has_tlc_offload(mvm))
-               rs_fw_rate_init(mvm, sta, band);
+               rs_fw_rate_init(mvm, sta, band, update);
        else
                rs_drv_rate_init(mvm, sta, band, update);
 }
index 8e7f993e29116b06a2ee16c0486188d8a0022d4a..d0f47899f2849505eb60d5343f19c216f8e3fb3c 100644 (file)
@@ -461,7 +461,7 @@ void rs_remove_sta_debugfs(void *mvm, void *mvm_sta);
 
 void iwl_mvm_rs_add_sta(struct iwl_mvm *mvm, struct iwl_mvm_sta *mvmsta);
 void rs_fw_rate_init(struct iwl_mvm *mvm, struct ieee80211_sta *sta,
-                    enum nl80211_band band);
+                    enum nl80211_band band, bool update);
 int rs_fw_tx_protection(struct iwl_mvm *mvm, struct iwl_mvm_sta *mvmsta,
                        bool enable);
 void iwl_mvm_tlc_update_notif(struct iwl_mvm *mvm,