Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drivers/firmware: psci: Convert timers to use timer_setup()

In preparation for unconditionally passing the struct timer_list pointer to
all timer callbacks, switch to using the new timer_setup() and from_timer()
to pass the timer pointer explicitly. Also adds missing call to
destroy_timer_on_stack().

Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Cc: linux-arm-kernel@lists.infradead.org
Signed-off-by: Kees Cook <keescook@chromium.org>

+2 -2
+2 -2
drivers/firmware/psci_checker.c
··· 220 220 return err; 221 221 } 222 222 223 - static void dummy_callback(unsigned long ignored) {} 223 + static void dummy_callback(struct timer_list *unused) {} 224 224 225 225 static int suspend_cpu(int index, bool broadcast) 226 226 { ··· 287 287 pr_info("CPU %d entering suspend cycles, states 1 through %d\n", 288 288 cpu, drv->state_count - 1); 289 289 290 - setup_timer_on_stack(&wakeup_timer, dummy_callback, 0); 290 + timer_setup_on_stack(&wakeup_timer, dummy_callback, 0); 291 291 for (i = 0; i < NUM_SUSPEND_CYCLE; ++i) { 292 292 int index; 293 293 /*