提交 790d5c8d 编写于 作者: T Tejun Heo 提交者: Dmitry Torokhov

Input: hp680_ts_input - use cancel_delayed_work_sync()

Make hp680_ts_init/exit() call cancel_delayed_work_sync() instead of
calling cancel_delayed_work() followed by flush_scheduled_work().

This is to prepare for the deprecation and removal of
flush_scheduled_work().
Signed-off-by: NTejun Heo <tj@kernel.org>
Signed-off-by: NDmitry Torokhov <dtor@mail.ru>
上级 f74eef95
...@@ -107,8 +107,7 @@ static int __init hp680_ts_init(void) ...@@ -107,8 +107,7 @@ static int __init hp680_ts_init(void)
return 0; return 0;
fail2: free_irq(HP680_TS_IRQ, NULL); fail2: free_irq(HP680_TS_IRQ, NULL);
cancel_delayed_work(&work); cancel_delayed_work_sync(&work);
flush_scheduled_work();
fail1: input_free_device(hp680_ts_dev); fail1: input_free_device(hp680_ts_dev);
return err; return err;
} }
...@@ -116,8 +115,7 @@ static int __init hp680_ts_init(void) ...@@ -116,8 +115,7 @@ static int __init hp680_ts_init(void)
static void __exit hp680_ts_exit(void) static void __exit hp680_ts_exit(void)
{ {
free_irq(HP680_TS_IRQ, NULL); free_irq(HP680_TS_IRQ, NULL);
cancel_delayed_work(&work); cancel_delayed_work_sync(&work);
flush_scheduled_work();
input_unregister_device(hp680_ts_dev); input_unregister_device(hp680_ts_dev);
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册