summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/intel/iwlwifi/mvm/mld-mac80211.c
diff options
context:
space:
mode:
authorMiri Korenblit <miriam.rachel.korenblit@intel.com>2024-04-16 13:54:04 +0300
committerJohannes Berg <johannes.berg@intel.com>2024-04-19 10:16:33 +0200
commit6cf7df9f013f44b1f94da75e3e01410231535430 (patch)
tree367c883dc6db27ebefd968920166506d76da56cf /drivers/net/wireless/intel/iwlwifi/mvm/mld-mac80211.c
parent07bf5297d392069021055800ef48a1106a5c85b5 (diff)
wifi: iwlwifi: mvm: Add helper functions to update EMLSR status
There are reasons for which we need to exit EMLSR, but not to block it completely, and there are reasons for which we need to block EMLSR. For both reason types we have the enum iwl_mvm_esr_state, when the blocking reasons are stored in the `mvmvif::esr_disable_reason` bitmap. This change introduces the APIs to use in the different cases: - iwl_mvm_exit_esr - will exit from EMLSR mode. - iwl_mvm_block_esr - will update the bitmap and exit EMLSR, to be used for the blocking reasons only. - iwl_mvm_unblock_esr - will update the bitmap. To be used for the blocking reasons only. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Johannes Berg <johannes.berg@intel.com> Link: https://msgid.link/20240416134215.d54142a75876.I552926065521f5f848c37b0bd845494bd7865fb7@changeid Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'drivers/net/wireless/intel/iwlwifi/mvm/mld-mac80211.c')
-rw-r--r--drivers/net/wireless/intel/iwlwifi/mvm/mld-mac80211.c24
1 files changed, 1 insertions, 23 deletions
diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/mld-mac80211.c b/drivers/net/wireless/intel/iwlwifi/mvm/mld-mac80211.c
index 105ac43e4cd7..2a7d7d4e0649 100644
--- a/drivers/net/wireless/intel/iwlwifi/mvm/mld-mac80211.c
+++ b/drivers/net/wireless/intel/iwlwifi/mvm/mld-mac80211.c
@@ -1151,28 +1151,6 @@ iwl_mvm_mld_change_sta_links(struct ieee80211_hw *hw,
return ret;
}
-void iwl_mvm_recalc_esr(struct iwl_mvm *mvm, struct ieee80211_vif *vif)
-{
- struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif);
- bool enable = !mvmvif->esr_disable_reason;
- u16 new_active_links;
-
- /* Nothing to do */
- if (mvmvif->esr_active == enable)
- return;
-
- /* The next link selection will enter eSR if possible */
- if (enable)
- return;
-
- /*
- * Find the primary link, as we want to switch to it and drop the
- * secondary one.
- */
- new_active_links = BIT(iwl_mvm_get_primary_link(vif));
- ieee80211_set_active_links_async(vif, new_active_links);
-}
-
bool iwl_mvm_esr_allowed_on_vif(struct iwl_mvm *mvm,
struct ieee80211_vif *vif)
{
@@ -1194,7 +1172,7 @@ bool iwl_mvm_esr_allowed_on_vif(struct iwl_mvm *mvm,
!(ext_capa->eml_capabilities & IEEE80211_EML_CAP_EMLSR_SUPP))
return false;
- return !(mvmvif->esr_disable_reason & ~IWL_MVM_ESR_DISABLE_COEX);
+ return !(mvmvif->esr_disable_reason & ~IWL_MVM_ESR_BLOCKED_COEX);
}
/*