Skip to content

Commit 1a2ff5c

Browse files
covanamKAGA-KOKO
authored andcommitted
drm/i915/request: Switch to use hrtimer_setup()
hrtimer_setup() takes the callback function pointer as argument and initializes the timer completely. Replace hrtimer_init() and the open coded initialization of hrtimer::function with the new setup mechanism. Patch was created by using Coccinelle. Signed-off-by: Nam Cao <[email protected]> Signed-off-by: Thomas Gleixner <[email protected]> Acked-by: Zack Rusin <[email protected]> Acked-by: Jani Nikula <[email protected]> Link: https://lore.kernel.org/all/4fe658e6d8483e44d4fff579bc426e627487f6ca.1738746904.git.namcao@linutronix.de
1 parent f97e1d7 commit 1a2ff5c

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

drivers/gpu/drm/i915/i915_request.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -293,8 +293,7 @@ static void __rq_init_watchdog(struct i915_request *rq)
293293
{
294294
struct i915_request_watchdog *wdg = &rq->watchdog;
295295

296-
hrtimer_init(&wdg->timer, CLOCK_MONOTONIC, HRTIMER_MODE_REL);
297-
wdg->timer.function = __rq_watchdog_expired;
296+
hrtimer_setup(&wdg->timer, __rq_watchdog_expired, CLOCK_MONOTONIC, HRTIMER_MODE_REL);
298297
}
299298

300299
static void __rq_arm_watchdog(struct i915_request *rq)

0 commit comments

Comments
 (0)