Skip to content

Commit 7cd6986

Browse files
jmberg-intelgregkh
authored andcommitted
iwlwifi: pcie: fix context info freeing
[ Upstream commit 26d18c7 ] After firmware alive, iwl_trans_pcie_gen2_fw_alive() is called to free the context info. However, on gen3 that will then free the context info with the wrong size. Since we free this allocation later, let it stick around until the device is stopped for now, freeing some of it earlier is a separate change. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> Link: https://lore.kernel.org/r/iwlwifi.20210618105614.afb63fb8cbc1.If4968db8e09f4ce2a1d27a6d750bca3d132d7d70@changeid Signed-off-by: Luca Coelho <luciano.coelho@intel.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
1 parent b98ec6d commit 7cd6986

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

‎drivers/net/wireless/intel/iwlwifi/pcie/trans-gen2.c‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,8 @@ void iwl_trans_pcie_gen2_fw_alive(struct iwl_trans *trans, u32 scd_addr)
269269
/* now that we got alive we can free the fw image & the context info.
270270
* paging memory cannot be freed included since FW will still use it
271271
*/
272-
iwl_pcie_ctxt_info_free(trans);
272+
if (trans->trans_cfg->device_family < IWL_DEVICE_FAMILY_AX210)
273+
iwl_pcie_ctxt_info_free(trans);
273274

274275
/*
275276
* Re-enable all the interrupts, including the RF-Kill one, now that

0 commit comments

Comments
 (0)