wifi: ath11k: disable wake IRQ on AHB suspend failure
PATCH 1/1 wifi: ath11k: disable wake IRQ on AHB suspend failure
ath11k_ahb_hif_suspend() enables the wake IRQ before sending the SMP2P power-save-enter message. If qcom_smem_state_update_bits() fails, the function returns without balancing enable_irq_wake(). The WoW suspend error path does not call ath11k_ahb_hif_resume(), so its wake IRQ cleanup does not undo this enable.
Disable the wake IRQ before returning the SMP2P error. Warn if disabling it also fails, while preserving the original error code.
This issue was identified during our ongoing static-analysis research while reviewing kernel code.
Fixes 69ccee619a38 ("wifi: ath11k: Add WoW support for WCN6750")
Co-developed-by Ijae Kim <[email protected]>
Signed-off-by Ijae Kim <[email protected]>
Signed-off-by Myeonghun Pak <[email protected]>
--- drivers/net/wireless/ath/ath11k/ahb.c | 2 ++ 1 file changed, 2 insertions(+)
drivers/net/wireless/ath/ath11k/ahb.c +2 -0
@@ -742,6 +742,8 @@ static int ath11k_ahb_hif_suspend(struct ath11k_base *ab) ATH11K_AHB_SMP2P_SMEM_VALUE_MASK, value);if (ret) {ath11k_err (ab,"failed to send smp2p power save enter cmd :%d\n" , ret); +if (disable_irq_wake (wake_irq)) +ath11k_warn (ab,"failed to disable wakeup irq on suspend failure\n" );return ret; }
base-commit: 08df884136f1c1197bab2a27814404fd329d9aac
Signature · 1 line
2.50.1