]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
wifi: iwlwifi: don't warn when if there is a FW error
authorMiri Korenblit <miriam.rachel.korenblit@intel.com>
Sat, 8 Mar 2025 21:19:23 +0000 (23:19 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 29 May 2025 09:12:47 +0000 (11:12 +0200)
[ Upstream commit c7f50d0433a016d43681592836a3d484817bfb34 ]

iwl_trans_reclaim is warning if it is called when the FW is not alive.
But if it is called when there is a pending restart, i.e. after a FW
error, there is no need to warn, instead - return silently.

Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20250308231427.ba3d90b22c25.I9332506af1997faefcf0bdb51d98d5e874051722@changeid
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/wireless/intel/iwlwifi/iwl-trans.c

index ced8261c725f8ce9a64ddff475fc4d21aa384c2a..eb631080c4563192c8381cf44da113ab8a19b236 100644 (file)
@@ -2,7 +2,7 @@
 /*
  * Copyright (C) 2015 Intel Mobile Communications GmbH
  * Copyright (C) 2016-2017 Intel Deutschland GmbH
- * Copyright (C) 2019-2021, 2023-2024 Intel Corporation
+ * Copyright (C) 2019-2021, 2023-2025 Intel Corporation
  */
 #include <linux/kernel.h>
 #include <linux/bsearch.h>
@@ -655,6 +655,9 @@ IWL_EXPORT_SYMBOL(iwl_trans_tx);
 void iwl_trans_reclaim(struct iwl_trans *trans, int queue, int ssn,
                       struct sk_buff_head *skbs, bool is_flush)
 {
+       if (unlikely(test_bit(STATUS_FW_ERROR, &trans->status)))
+               return;
+
        if (WARN_ONCE(trans->state != IWL_TRANS_FW_ALIVE,
                      "bad state = %d\n", trans->state))
                return;