]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
wifi: ath12k: Replace lock/unlock with guard()
authorRipan Deuri <quic_rdeuri@quicinc.com>
Mon, 3 Nov 2025 11:21:11 +0000 (16:51 +0530)
committerJeff Johnson <jeff.johnson@oss.qualcomm.com>
Wed, 5 Nov 2025 15:16:56 +0000 (07:16 -0800)
commitf87034a7576f918f2e60a14f17185b492e91580d
treedf3dc84d7b5fadd12dd49ed3f6b84b66e73e428a
parent96b42732bc75de66c5e10c67d6a60967004ceead
wifi: ath12k: Replace lock/unlock with guard()

Use guard(wiphy)(...) and guard(spinlock_bh)(...) in:

ath12k_dbg_sta_dump_rx_stats()
ath12k_mac_op_link_sta_statistics()

The guard() API ensures locks are automatically released when the scope
exits, reducing the risk of missing unlocks in error paths and improving
code readability.

Tested-on: QCN9274 hw2.0 PCI WLAN.WBE.1.4.1-00199-QCAHKSWPL_SILICONZ-1
Tested-on: WCN7850 hw2.0 PCI WLAN.HMT.1.0.c5-00481-QCAHMTSWPL_V1.0_V2.0_SILICONZ-3

Signed-off-by: Ripan Deuri <quic_rdeuri@quicinc.com>
Reviewed-by: Karthikeyan Periyasamy <karthikeyan.periyasamy@oss.qualcomm.com>
Reviewed-by: Baochen Qiang <baochen.qiang@oss.qualcomm.com>
Link: https://patch.msgid.link/20251103112111.2260639-13-quic_rdeuri@quicinc.com
Signed-off-by: Jeff Johnson <jeff.johnson@oss.qualcomm.com>
drivers/net/wireless/ath/ath12k/debugfs_sta.c
drivers/net/wireless/ath/ath12k/mac.c