]> www.infradead.org Git - users/willy/pagecache.git/commit
wifi: iwlwifi: mvm: fix PNVM timeout for non-MSI-X platforms
authorEmmanuel Grumbach <emmanuel.grumbach@intel.com>
Thu, 6 Mar 2025 10:25:47 +0000 (12:25 +0200)
committerJohannes Berg <johannes.berg@intel.com>
Fri, 7 Mar 2025 08:57:39 +0000 (09:57 +0100)
commitb8c8a03e9b7bfc06f366b75daf3d0812400e7123
tree1efe2fabe1f840f24d334ee5bdff2b967daa3c94
parentbbb18f7e23a3f5f56d5c8b4ee0f78f00edb3b1b2
wifi: iwlwifi: mvm: fix PNVM timeout for non-MSI-X platforms

When MSI-X is not enabled, we mask all the interrupts in the interrupt
handler and re-enable them when the interrupt thread runs. If
STATUS_INT_ENABLED is not set, we won't re-enable in the thread.
In order to get the ALIVE interrupt, we allow the ALIVE interrupt
itself, and RX as well in order to receive the ALIVE notification (which
is received as an RX from the firmware.

The problem is that STATUS_INT_ENABLED is clear until the op_mode calls
trans_fw_alive which means that until trans_fw_alive is called, any
notification from the firmware will not be received.

This became a problem when we inserted the pnvm_load exactly between the
ALIVE and trans_fw_alive.

Fix that by calling trans_fw_alive before loading the PNVM. This will
allow to get the notification from the firmware about PNVM load being
complete and continue the flow normally.

This didn't happen on MSI-X because we don't disable the interrupts in
the ISR when MSI-X is available.

The error in the log looks like this:

iwlwifi 0000:00:03.0: Timeout waiting for PNVM load!
iwlwifi 0000:00:03.0: Failed to start RT ucode: -110
iwlwifi 0000:00:03.0: WRT: Collecting data: ini trigger 13 fired (delay=0ms).

Fixes: 70d3ca86b025 ("iwlwifi: mvm: ring the doorbell and wait for PNVM load completion")
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Reviewed-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20250306122425.0f2cf207aae1.I025d8f724b44f52eadf6c19069352eb9275613a8@changeid
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
drivers/net/wireless/intel/iwlwifi/mvm/fw.c