]> git.hungrycats.org Git - linux/commit
Input: cs40l50 - fix wrong usage of INIT_WORK()
authorYuan Can <yuancan@huawei.com>
Fri, 8 Nov 2024 05:52:23 +0000 (21:52 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 5 Dec 2024 12:54:26 +0000 (13:54 +0100)
commit85211611661f3cd33ea9a0286368cea03486f0d2
tree8a403953f08318690e2e87728c532752a925fca0
parent8fed302872e26c7bf44d855c53a1cde747172d58
Input: cs40l50 - fix wrong usage of INIT_WORK()

commit 5c822c0ce5cc83ed4cd8394f3dc46dae8d9a681d upstream.

In cs40l50_add(), the work_data is a local variable and the work_data.work
should initialize with INIT_WORK_ONSTACK() instead of INIT_WORK().
Small error in cs40l50_erase() also fixed in this commit.

Fixes: c38fe1bb5d21 ("Input: cs40l50 - Add support for the CS40L50 haptic driver")
Signed-off-by: Yuan Can <yuancan@huawei.com>
Reviewed-by: James Ogletree <jogletre@opensource.cirrus.com>
Link: https://lore.kernel.org/r/20241106013549.78142-1-yuancan@huawei.com
Cc: stable@vger.kernel.org
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/input/misc/cs40l50-vibra.c