[PATCH 1/2] ARM: irq: Call irqchit_init if no init_irq function is specified
Arnd Bergmann
arnd at arndb.de
Thu Mar 28 11:25:42 EDT 2013
On Thursday 28 March 2013, Russell King - ARM Linux wrote:
> Better:
>
> #ifdef CONFIG_OF
> if (!machine_desc->init_irq)
> irqchip_init();
> else
> #endif
> machine_desc->init_irq();
>
> which means we don't even get the test if !OF, and if someone mistakenly
> sets this to NULL for a !OF platform, they get to know about it.
Right. With the new IS_DEFINED() macro, we could even turn this into
if (IS_DEFINED(CONFIG_OF) && !machine_desc->init_irq)
irqchip_init();
else
machine_desc->init_irq();
to the same effect.
Arnd
More information about the linux-arm-kernel
mailing list