]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
wifi: ath11k: validate ath11k_crypto_mode on top of ath11k_core_qmi_firmware_ready
authorRodrigo Gobbi <rodrigo.gobbi.7@gmail.com>
Thu, 22 May 2025 20:01:12 +0000 (17:01 -0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 27 Jun 2025 10:07:21 +0000 (11:07 +0100)
commit9ae9cfd1834e69ecdb7b33686042aaec12b3e219
tree84c92ad752e1c5b661ec77a6e5e40d2d3dde029c
parent62be3a9b3433c8c2062de43bb32a35736a6d2fda
wifi: ath11k: validate ath11k_crypto_mode on top of ath11k_core_qmi_firmware_ready

[ Upstream commit b0d226a60856a1b765bb9a3848c7b2322fd08c47 ]

if ath11k_crypto_mode is invalid (not ATH11K_CRYPT_MODE_SW/ATH11K_CRYPT_MODE_HW),
ath11k_core_qmi_firmware_ready() will not undo some actions that was previously
started/configured. Do the validation as soon as possible in order to avoid
undoing actions in that case and also to fix the following smatch warning:

drivers/net/wireless/ath/ath11k/core.c:2166 ath11k_core_qmi_firmware_ready()
warn: missing unwind goto?

Signed-off-by: Rodrigo Gobbi <rodrigo.gobbi.7@gmail.com>
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <error27@gmail.com>
Closes: https://lore.kernel.org/r/202304151955.oqAetVFd-lkp@intel.com/
Fixes: aa2092a9bab3 ("ath11k: add raw mode and software crypto support")
Reviewed-by: Baochen Qiang <quic_bqiang@quicinc.com>
Link: https://patch.msgid.link/20250522200519.16858-1-rodrigo.gobbi.7@gmail.com
Signed-off-by: Jeff Johnson <jeff.johnson@oss.qualcomm.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/wireless/ath/ath11k/core.c