]> git.ipfire.org Git - thirdparty/linux.git/commit
counter: ftm-quaddec: use devm_mutex_init()
authorStepan Ionichev <sozdayvek@gmail.com>
Sat, 23 May 2026 18:43:51 +0000 (23:43 +0500)
committerWilliam Breathitt Gray <wbg@kernel.org>
Wed, 27 May 2026 22:12:18 +0000 (07:12 +0900)
commitb400c076fe4b63576fa22fbb59078b030000970c
tree6e82a1dad6af427e6d22b549ad24088f6fa42543
parentee4133b921a17b239ca617e9b0c16cad1277e9fd
counter: ftm-quaddec: use devm_mutex_init()

ftm_quaddec_probe() calls mutex_init() but neither the cleanup
action nor a remove callback issues a matching mutex_destroy(),
so the lock debug state is leaked on driver unbind.

Switch to devm_mutex_init() so the mutex is torn down in the same
devm scope it was set up in.

Signed-off-by: Stepan Ionichev <sozdayvek@gmail.com>
Reviewed-by: Joshua Crofts <joshua.crofts1@gmail.com>
Link: https://lore.kernel.org/r/20260523184351.7567-1-sozdayvek@gmail.com
Signed-off-by: William Breathitt Gray <wbg@kernel.org>
drivers/counter/ftm-quaddec.c