diff --git a/drivers/gpu/drm/i915/selftests/lib_sw_fence.c b/drivers/gpu/drm/i915/selftests/lib_sw_fence.c index b26f07b55d861c04b45dbad8d56c4ea9cd414540..3790fdf44a1ab7feb4429c76d8524ea50926864b 100644 --- a/drivers/gpu/drm/i915/selftests/lib_sw_fence.c +++ b/drivers/gpu/drm/i915/selftests/lib_sw_fence.c @@ -49,9 +49,9 @@ void onstack_fence_fini(struct i915_sw_fence *fence) i915_sw_fence_fini(fence); } -static void timed_fence_wake(struct timer_list *t) +static void timed_fence_wake(unsigned long data) { - struct timed_fence *tf = from_timer(tf, t, timer); + struct timed_fence *tf = (struct timed_fence *)data; i915_sw_fence_commit(&tf->fence); } @@ -60,7 +60,7 @@ void timed_fence_init(struct timed_fence *tf, unsigned long expires) { onstack_fence_init(&tf->fence); - timer_setup_on_stack(&tf->timer, timed_fence_wake, 0); + setup_timer_on_stack(&tf->timer, timed_fence_wake, (unsigned long)tf); if (time_after(expires, jiffies)) mod_timer(&tf->timer, expires);