]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
wifi: cw1200: Fix locking in error paths
authorBart Van Assche <bvanassche@acm.org>
Mon, 23 Feb 2026 22:00:24 +0000 (14:00 -0800)
committerJohannes Berg <johannes.berg@intel.com>
Tue, 3 Mar 2026 11:00:51 +0000 (12:00 +0100)
commitd98c24617a831e92e7224a07dcaed2dd0b02af96
tree9f1b5944c6208e7e5d238b6a0cede77b34131d61
parent8fb54c7307f6add04246d2f7845e42ecd41950fe
wifi: cw1200: Fix locking in error paths

cw1200_wow_suspend() must only return with priv->conf_mutex locked if it
returns zero. This mutex must be unlocked if an error is returned. Add
mutex_unlock() calls to the error paths from which that call is missing.
This has been detected by the Clang thread-safety analyzer.

Fixes: a910e4a94f69 ("cw1200: add driver for the ST-E CW1100 & CW1200 WLAN chipsets")
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Link: https://patch.msgid.link/20260223220102.2158611-25-bart.vanassche@linux.dev
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
drivers/net/wireless/st/cw1200/pm.c