Skip to content

Commit

Permalink
Input: tsc2005 - use relative jiffies to schedule the watchdog
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
Aaro Koskinen authored and Dmitry Torokhov committed Mar 24, 2011
1 parent ddca6a3 commit 9034279
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/input/touchscreen/tsc2005.c
Original file line number Diff line number Diff line change
Expand Up @@ -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)));
}

Expand Down Expand Up @@ -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);
}
Expand Down

0 comments on commit 9034279

Please sign in to comment.