[RFC 3/5] ARM: OMAP2+: timer: Add clocksource initialization and powerup support

Rob Herring robh at kernel.org
Fri Mar 14 17:16:39 EDT 2014


On Fri, Mar 14, 2014 at 4:09 PM, Kevin Hilman <khilman at linaro.org> wrote:
> Joel Fernandes <joelf at ti.com> writes:
>
>> On 03/13/2014 04:52 PM, Rob Herring wrote:
>>> On Thu, Mar 13, 2014 at 3:35 PM, Joel Fernandes <joelf at ti.com> wrote:
>>>> Introduce a generic omap timer initialization function that can
>>>> be used by all SoCs for which support is available in the clocksource
>>>> driver introduced in the series.
>>>>
>>>> The function will also be responsible for calling clock initialization
>>>> required for everything else to work.
>>>>
>>>> Signed-off-by: Joel Fernandes <joelf at ti.com>

[snip]

>>>> +void omap_generic_timer_init(void)
>>>> +{
>>>> +       if (!of_have_populated_dt())
>>>> +               BUG_ON("Generic timer init should only be used for DT boot\n");
>>>
>>> I thought omap2 is always DT boot now.
>>
>> That's right, sorry- I'll get rid of the check.
>
> Actually, mainline still supports legacy boot and has board files for
> OMAP3 platforms, and we shouldn't break legacy boot on purpose IMO.

It is not breaking anything. You'd have to call this function
mistakenly from a legacy machine desc or other non-DT boot path. It's
a question of how paranoid you are adding checks. IMHO, the BUG_ON is
quite pointless here. You are not likely to progress much further
anyway, and you won't see the BUG print because the serial port is not
up yet.

Rob



More information about the linux-arm-kernel mailing list