diff options
author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2019-02-07 14:39:40 -0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-03-23 13:19:41 +0100 |
commit | 8faa6f2fc2934de64183cc308a388621ea53d39a (patch) | |
tree | 446c14c2f8587f9d2d7a659c903b64f30b6dde3c /drivers/input | |
parent | 3c8b39a0a42bfa129886786efe8ef071ad355818 (diff) |
Input: matrix_keypad - use flush_delayed_work()
[ Upstream commit a342083abe576db43594a32d458a61fa81f7cb32 ]
We should be using flush_delayed_work() instead of flush_work() in
matrix_keypad_stop() to ensure that we are not missing work that is
scheduled but not yet put in the workqueue (i.e. its delay timer has not
expired yet).
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'drivers/input')
-rw-r--r-- | drivers/input/keyboard/matrix_keypad.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/input/keyboard/matrix_keypad.c b/drivers/input/keyboard/matrix_keypad.c index c64d87442a62..2e12e31f45c5 100644 --- a/drivers/input/keyboard/matrix_keypad.c +++ b/drivers/input/keyboard/matrix_keypad.c @@ -220,7 +220,7 @@ static void matrix_keypad_stop(struct input_dev *dev) keypad->stopped = true; spin_unlock_irq(&keypad->lock); - flush_work(&keypad->work.work); + flush_delayed_work(&keypad->work); /* * matrix_keypad_scan() will leave IRQs enabled; * we should disable them now. |