wifi: ath12k: do not restore ASPM in case of single MSI vector
authorKang Yang <quic_kangyang@quicinc.com>
Fri, 1 Dec 2023 16:09:47 +0000 (18:09 +0200)
committerKalle Valo <quic_kvalo@quicinc.com>
Tue, 5 Dec 2023 15:04:19 +0000 (17:04 +0200)
commit08d52ba2967898723bf6fc57a9fb5dc0018cc5bc
tree91230ccf0643008618fd256a46d131395a5ab8f2
parent8398654398c2a97d28a3f0cc97e9a1f2e99113b9
wifi: ath12k: do not restore ASPM in case of single MSI vector

Current code enables ASPM by default, it allows MHI to enter M2 state.
In case of one MSI vector, system hang is observed if ath12k does MHI
register reading in this state.

The workaround here is to prevent MHI from entering M2 state, this can
be done by disabling ASPM if only one MSI vector is used. When using 32
vectors ASPM is enabled as before.

Tested-on: WCN7850 hw2.0 PCI WLAN.HMT.1.0-03427-QCAHMTSWPL_V1.0_V2.0_SILICONZ-1.15378.4

Signed-off-by: Kang Yang <quic_kangyang@quicinc.com>
Acked-by: Jeff Johnson <quic_jjohnson@quicinc.com>
Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com>
Link: https://lore.kernel.org/r/20231121021304.12966-7-quic_kangyang@quicinc.com
drivers/net/wireless/ath/ath12k/pci.c