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: Tejun Heo <tj@kernel.org>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
This commit is contained in:
Tejun Heo 2010-10-15 09:47:15 -07:00 committed by Dmitry Torokhov
parent f74eef95e3
commit 790d5c8dac

View File

@ -107,8 +107,7 @@ static int __init hp680_ts_init(void)
return 0;
fail2: free_irq(HP680_TS_IRQ, NULL);
cancel_delayed_work(&work);
flush_scheduled_work();
cancel_delayed_work_sync(&work);
fail1: input_free_device(hp680_ts_dev);
return err;
}
@ -116,8 +115,7 @@ static int __init hp680_ts_init(void)
static void __exit hp680_ts_exit(void)
{
free_irq(HP680_TS_IRQ, NULL);
cancel_delayed_work(&work);
flush_scheduled_work();
cancel_delayed_work_sync(&work);
input_unregister_device(hp680_ts_dev);
}