提交 134891e1 编写于 作者: D Dmitry Torokhov 提交者: Greg Kroah-Hartman

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: NDmitry Torokhov <dmitry.torokhov@gmail.com>
Signed-off-by: NSasha Levin <sashal@kernel.org>
上级 e91dc209
...@@ -222,7 +222,7 @@ static void matrix_keypad_stop(struct input_dev *dev) ...@@ -222,7 +222,7 @@ static void matrix_keypad_stop(struct input_dev *dev)
keypad->stopped = true; keypad->stopped = true;
spin_unlock_irq(&keypad->lock); spin_unlock_irq(&keypad->lock);
flush_work(&keypad->work.work); flush_delayed_work(&keypad->work);
/* /*
* matrix_keypad_scan() will leave IRQs enabled; * matrix_keypad_scan() will leave IRQs enabled;
* we should disable them now. * we should disable them now.
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册