diff mbox series

[5/5] wifi: iwlwifi: mei: fix parameter passing to iwl_mei_alive_notif()

Message ID 20221123225313.83c2251055c1.Ia028357e7ab36dfc2abf85106a5926ee7893a408@changeid (mailing list archive)
State Accepted
Commit 871b105ad874361665fe0025fcf8fc7ab8ed24d0
Delegated to: Gregory Greenman
Headers show
Series updates and fixes intended for v6.2 2022-11-23 | expand

Commit Message

Greenman, Gregory Nov. 23, 2022, 9:02 p.m. UTC
From: Gregory Greenman <gregory.greenman@intel.com>

Pass true explicitly to iwl_mei_alive_notif() when we can be
sure that Alive notification was received. The issue was discovered
by Smatch.

Reported-by: Dan Carpenter <error27@gmail.com>
Link: https://lore.kernel.org/all/Y3uYUEFnMiBY2ABQ@kili/
Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
---
 drivers/net/wireless/intel/iwlwifi/mvm/fw.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/fw.c b/drivers/net/wireless/intel/iwlwifi/mvm/fw.c
index 2f4c9e653e99..0a41cd0ab243 100644
--- a/drivers/net/wireless/intel/iwlwifi/mvm/fw.c
+++ b/drivers/net/wireless/intel/iwlwifi/mvm/fw.c
@@ -418,7 +418,8 @@  static int iwl_mvm_load_ucode_wait_alive(struct iwl_mvm *mvm,
 		return -EIO;
 	}
 
-	iwl_mei_alive_notif(!ret);
+	/* if reached this point, Alive notification was received */
+	iwl_mei_alive_notif(true);
 
 	ret = iwl_pnvm_load(mvm->trans, &mvm->notif_wait);
 	if (ret) {