1
0
Fork 0

clocksource/drivers/tegra: Reset hardware state on init

Reset timer's hardware state to ensure that initially it is in a
predictable state.

Signed-off-by: Dmitry Osipenko <digetx@gmail.com>
Acked-By: Peter De Schrijver <pdeschrijver@nvidia.com>
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
alistair/sunxi64-5.4-dsi
Dmitry Osipenko 2019-06-03 21:59:41 +03:00 committed by Daniel Lezcano
parent af8d9129ec
commit 77d57d1d80
1 changed files with 3 additions and 0 deletions

View File

@ -123,6 +123,9 @@ static int tegra_timer_setup(unsigned int cpu)
{
struct timer_of *to = per_cpu_ptr(&tegra_to, cpu);
writel(0, timer_of_base(to) + TIMER_PTV);
writel(TIMER_PCR_INTR_CLR, timer_of_base(to) + TIMER_PCR);
irq_force_affinity(to->clkevt.irq, cpumask_of(cpu));
enable_irq(to->clkevt.irq);