iwlwifi: mvm: don't iterate unadded vifs when handling FW SMPS req
authorLuca Coelho <luciano.coelho@intel.com>
Sat, 29 Jan 2022 11:16:15 +0000 (13:16 +0200)
committerLuca Coelho <luciano.coelho@intel.com>
Fri, 18 Feb 2022 08:40:51 +0000 (10:40 +0200)
We may not have all the interfaces added to the driver when we get the
THERMAL_DUAL_CHAIN_REQUEST notification from the FW, so instead of
iterating all vifs to update SMPS, iterate only the ones that are
already assigned.  The interfaces that were not assigned yet, will be
updated accordingly when we start using them.

Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Fixes: 2a7ce54ccc23 ("iwlwifi: mvm: honour firmware SMPS requests")
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Link: https://lore.kernel.org/r/iwlwifi.20220129105618.9416aade2ba0.I0b71142f89e3f158aa058a1dfb2517c8c1fa3726@changeid
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
drivers/net/wireless/intel/iwlwifi/mvm/ops.c

index 16665fe22eb1ee4f24f30724cb1f6b988dc59369..d3122a3870b9b5b4e6e1b78b911aa502b05e1563 100644 (file)
@@ -235,7 +235,8 @@ static void iwl_mvm_rx_thermal_dual_chain_req(struct iwl_mvm *mvm,
         */
        mvm->fw_static_smps_request =
                req->event == cpu_to_le32(THERMAL_DUAL_CHAIN_REQ_DISABLE);
-       ieee80211_iterate_interfaces(mvm->hw, IEEE80211_IFACE_ITER_NORMAL,
+       ieee80211_iterate_interfaces(mvm->hw,
+                                    IEEE80211_IFACE_SKIP_SDATA_NOT_IN_DRIVER,
                                     iwl_mvm_intf_dual_chain_req, NULL);
 }