mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2025-01-10 07:00:48 +00:00
Input: tsc2005 - use relative jiffies to schedule the watchdog
Use relative jiffies to schedule the watchdog. Otherwise it will run like a mad one. Signed-off-by: Aaro Koskinen <aaro.koskinen@nokia.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
This commit is contained in:
parent
ddca6a3134
commit
903427955b
@ -358,7 +358,7 @@ static void __tsc2005_enable(struct tsc2005 *ts)
|
||||
if (ts->esd_timeout && ts->set_reset) {
|
||||
ts->last_valid_interrupt = jiffies;
|
||||
schedule_delayed_work(&ts->esd_work,
|
||||
round_jiffies(jiffies +
|
||||
round_jiffies_relative(
|
||||
msecs_to_jiffies(ts->esd_timeout)));
|
||||
}
|
||||
|
||||
@ -512,7 +512,7 @@ static void tsc2005_esd_work(struct work_struct *work)
|
||||
out:
|
||||
/* re-arm the watchdog */
|
||||
schedule_delayed_work(&ts->esd_work,
|
||||
round_jiffies(jiffies +
|
||||
round_jiffies_relative(
|
||||
msecs_to_jiffies(ts->esd_timeout)));
|
||||
mutex_unlock(&ts->mutex);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user