[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250705160129.3688026-6-daniel.lezcano@linaro.org>
Date: Sat, 5 Jul 2025 18:01:12 +0200
From: Daniel Lezcano <daniel.lezcano@...aro.org>
To: daniel.lezcano@...aro.org,
tglx@...utronix.de
Cc: ghennadi.procopciuc@....nxp.com,
S32@....com,
linux-kernel@...r.kernel.org
Subject: [PATCH 06/20] clocksource/drivers/vf_pit: Encapsulate the initialization of the cycles_per_jiffy
Move the cycles_per_jiffy initialization to the same place where the
other pit timer fields are initialized.
No functional changes intended.
Signed-off-by: Daniel Lezcano <daniel.lezcano@...aro.org>
---
drivers/clocksource/timer-vf-pit.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/clocksource/timer-vf-pit.c b/drivers/clocksource/timer-vf-pit.c
index 20f637c8e856..3c1ac05626de 100644
--- a/drivers/clocksource/timer-vf-pit.c
+++ b/drivers/clocksource/timer-vf-pit.c
@@ -155,6 +155,7 @@ static int __init pit_clockevent_init(struct pit_timer *pit, void __iomem *base,
* for anyone else who needs them.
*/
pit->clkevt_base = base + PIT_CH(3);
+ pit->cycle_per_jiffy = rate / (HZ);
writel(0, pit->clkevt_base + PITTCTRL);
@@ -212,7 +213,6 @@ static int __init pit_timer_init(struct device_node *np)
return ret;
clk_rate = clk_get_rate(pit_clk);
- pit_timer.cycle_per_jiffy = clk_rate / (HZ);
/* enable the pit module */
writel(~PITMCR_MDIS, timer_base + PITMCR);
--
2.43.0
Powered by blists - more mailing lists