]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
net: pktgen: Switch to use hrtimer_setup_sleeper_on_stack()
authorNam Cao <namcao@linutronix.de>
Thu, 31 Oct 2024 15:14:26 +0000 (16:14 +0100)
committerThomas Gleixner <tglx@linutronix.de>
Thu, 7 Nov 2024 01:47:06 +0000 (02:47 +0100)
hrtimer_setup_sleeper_on_stack() replaces hrtimer_init_sleeper_on_stack()
to keep the naming convention consistent.

Convert the usage site over to it. The conversion was done with Coccinelle.

Signed-off-by: Nam Cao <namcao@linutronix.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Link: https://lore.kernel.org/all/c4b40b8fef250b6a325e1b8bd6057005fb3cb660.1730386209.git.namcao@linutronix.de
net/core/pktgen.c

index 34f68ef74b8f2cd2dbf8ba497b1e323d0636124b..7e23cacbe66e4ad8185a32e9eb5e005070a8ab1c 100644 (file)
@@ -2285,7 +2285,7 @@ static void spin(struct pktgen_dev *pkt_dev, ktime_t spin_until)
        s64 remaining;
        struct hrtimer_sleeper t;
 
-       hrtimer_init_sleeper_on_stack(&t, CLOCK_MONOTONIC, HRTIMER_MODE_ABS);
+       hrtimer_setup_sleeper_on_stack(&t, CLOCK_MONOTONIC, HRTIMER_MODE_ABS);
        hrtimer_set_expires(&t.timer, spin_until);
 
        remaining = ktime_to_ns(hrtimer_expires_remaining(&t.timer));