summaryrefslogtreecommitdiff
path: root/drivers/power
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2021-09-23 19:04:28 +0300
committerSebastian Reichel <sre@kernel.org>2021-09-25 00:35:11 +0300
commit067930724ecdca0e3a31b6d9e8c1b252b0976e68 (patch)
treebb982ddc88c6dd51f7870eb5c2768b9d9ca36aa2 /drivers/power
parent40a2d98c9763dbd05fa0eb7be96e161bb7e9d45c (diff)
downloadlinux-067930724ecdca0e3a31b6d9e8c1b252b0976e68.tar.xz
power: reset: ltc2952: Use hrtimer_forward_now()
hrtimer_forward_now() provides the same functionality as the open coded hrtimer_forward() invocation. Prepares for removal of hrtimer_forward() from the public interfaces. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: linux-pm@vger.kernel.org Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Diffstat (limited to 'drivers/power')
-rw-r--r--drivers/power/reset/ltc2952-poweroff.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/power/reset/ltc2952-poweroff.c b/drivers/power/reset/ltc2952-poweroff.c
index 8688c8ba8894..fbb344353fe4 100644
--- a/drivers/power/reset/ltc2952-poweroff.c
+++ b/drivers/power/reset/ltc2952-poweroff.c
@@ -94,7 +94,6 @@ static struct ltc2952_poweroff *ltc2952_data;
*/
static enum hrtimer_restart ltc2952_poweroff_timer_wde(struct hrtimer *timer)
{
- ktime_t now;
int state;
struct ltc2952_poweroff *data = to_ltc2952(timer, timer_wde);
@@ -104,8 +103,7 @@ static enum hrtimer_restart ltc2952_poweroff_timer_wde(struct hrtimer *timer)
state = gpiod_get_value(data->gpio_watchdog);
gpiod_set_value(data->gpio_watchdog, !state);
- now = hrtimer_cb_get_time(timer);
- hrtimer_forward(timer, now, data->wde_interval);
+ hrtimer_forward_now(timer, data->wde_interval);
return HRTIMER_RESTART;
}