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

clocksource/drivers/timer-imx-tpm: Specify clock name for timer-of

i.MX TPM needs "ipg" clock for register access and "per" clock for
timer function, the driver gets "ipg" clock by searching the clock
name, but timer-of initialization will get first clock in device
tree TPM node since no clock name specified in of_clk, that means
the "per" clock MUST be the first clock entry in device tree TPM
node, this patch specifies clock name for of_clk to avoid this
restriction, it makes TPM driver work properly with different sequence
of clock entries in device tree TPM node.

Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>

authored by

Anson Huang and committed by
Daniel Lezcano
4f352d1f 86fe57fc

+3
+3
drivers/clocksource/timer-imx-tpm.c
··· 139 139 .handler = tpm_timer_interrupt, 140 140 .flags = IRQF_TIMER | IRQF_IRQPOLL, 141 141 }, 142 + .of_clk = { 143 + .name = "per", 144 + }, 142 145 }; 143 146 144 147 static int __init tpm_clocksource_init(void)