Re: [PATCH v2 1/3] clocksource: davinci: only enable tim34 in periodic mode once it's initialized

From: Bartosz Golaszewski
Date: Fri Jan 10 2020 - 12:05:27 EST


pt., 10 sty 2020 o 00:12 Daniel Lezcano <daniel.lezcano@xxxxxxxxxx> napisaÅ(a):
>
> On 24/12/2019 11:03, Bartosz Golaszewski wrote:
> > From: Bartosz Golaszewski <bgolaszewski@xxxxxxxxxxxx>
> >
> > The DM365 platform has a strange quirk (only present when using ancient
> > u-boot - mainline u-boot v2013.01 and later works fine) where if we
> > enable the second half of the timer in periodic mode before we do its
> > initialization - the time won't start flowing and we can't boot.
> >
> > When using more recent u-boot, we can enable the timer, then reinitialize
> > it and all works fine.
> >
> > I've been unable to figure out why that is, but a workaround for this
> > is straightforward - don't enable the tim34 timer in periodic mode until
> > it's properly initialized.
> >
> > Signed-off-by: Bartosz Golaszewski <bgolaszewski@xxxxxxxxxxxx>
>
> Why not move clockevents_config_and_register() after
> davinci_clocksource_init_tim34() is called ?

Ha! Yes, that works too. I'll send a v3 shortly.

Bart