wifi: iwlwifi: mvm: make iwl_mvm_set_fw_mu_edca_params mld aware
authorEmmanuel Grumbach <emmanuel.grumbach@intel.com>
Tue, 20 Jun 2023 10:03:51 +0000 (13:03 +0300)
committerJohannes Berg <johannes.berg@intel.com>
Wed, 21 Jun 2023 12:02:15 +0000 (14:02 +0200)
We need to work on the right link there.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
Link: https://lore.kernel.org/r/20230620125813.8762a90e8857.Ic5b8e96140a449fd1ed7008907d67fc36fe98506@changeid
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
drivers/net/wireless/intel/iwlwifi/mvm/link.c
drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c
drivers/net/wireless/intel/iwlwifi/mvm/mvm.h

index 5fdebb911f7bc19c80b0a4881c67b9a2e0d566f0..ace82e2c5bd913bf54c917d2a67f1067b0622670 100644 (file)
@@ -188,7 +188,7 @@ int iwl_mvm_link_changed(struct iwl_mvm *mvm, struct ieee80211_vif *vif,
 
        /* TODO  how to set ndp_fdbk_buff_th_exp? */
 
-       if (iwl_mvm_set_fw_mu_edca_params(mvm, mvmvif,
+       if (iwl_mvm_set_fw_mu_edca_params(mvm, mvmvif->link[link_id],
                                          &cmd.trig_based_txf[0])) {
                flags |= LINK_FLG_MU_EDCA_CW;
                flags_mask |= LINK_FLG_MU_EDCA_CW;
index 4c0a9cc9ff7cd759f2c94877b8bfb161e273b161..ebe4163837a01831292df11586e0a50e55bfd65a 100644 (file)
@@ -2240,7 +2240,7 @@ int iwl_mvm_set_sta_pkt_ext(struct iwl_mvm *mvm,
  * is enabled or not
  */
 bool iwl_mvm_set_fw_mu_edca_params(struct iwl_mvm *mvm,
-                                  struct iwl_mvm_vif *mvmvif,
+                                  const struct iwl_mvm_vif_link_info *link_info,
                                   struct iwl_he_backoff_conf *trig_based_txf)
 {
        int i;
@@ -2248,11 +2248,11 @@ bool iwl_mvm_set_fw_mu_edca_params(struct iwl_mvm *mvm,
        bool mu_edca_enabled = true;
 
        for (i = 0; i < IEEE80211_NUM_ACS; i++) {
-               struct ieee80211_he_mu_edca_param_ac_rec *mu_edca =
-                       &mvmvif->deflink.queue_params[i].mu_edca_param_rec;
+               const struct ieee80211_he_mu_edca_param_ac_rec *mu_edca =
+                       &link_info->queue_params[i].mu_edca_param_rec;
                u8 ac = iwl_mvm_mac80211_ac_to_ucode_ac(i);
 
-               if (!mvmvif->deflink.queue_params[i].mu_edca) {
+               if (!link_info->queue_params[i].mu_edca) {
                        mu_edca_enabled = false;
                        break;
                }
@@ -2398,7 +2398,7 @@ static void iwl_mvm_cfg_he_sta(struct iwl_mvm *mvm,
 
        rcu_read_unlock();
 
-       if (iwl_mvm_set_fw_mu_edca_params(mvm, mvmvif,
+       if (iwl_mvm_set_fw_mu_edca_params(mvm, &mvmvif->deflink,
                                          &sta_ctxt_cmd.trig_based_txf[0]))
                flags |= STA_CTXT_HE_MU_EDCA_CW;
 
index 11de81b58515744fbf53468a247969152fb37455..b575ce2f71465b9a5ba9cd6d1bf5b2fc199be3c6 100644 (file)
@@ -1804,7 +1804,7 @@ void iwl_mvm_set_fw_qos_params(struct iwl_mvm *mvm, struct ieee80211_vif *vif,
                               struct ieee80211_bss_conf *link_conf,
                               struct iwl_ac_qos *ac, __le32 *qos_flags);
 bool iwl_mvm_set_fw_mu_edca_params(struct iwl_mvm *mvm,
-                                  struct iwl_mvm_vif *mvmvif,
+                                  const struct iwl_mvm_vif_link_info *link_info,
                                   struct iwl_he_backoff_conf *trig_based_txf);
 void iwl_mvm_set_fw_dtim_tbtt(struct iwl_mvm *mvm, struct ieee80211_vif *vif,
                              struct ieee80211_bss_conf *link_conf,