Re: linux-next: build warning after merge of the devicetree tree

From: Grant Likely
Date: Thu Oct 21 2010 - 13:04:37 EST


On Thu, Oct 21, 2010 at 10:05:26AM +0200, Ingo Molnar wrote:
> > On Thu, Oct 21, 2010 at 01:37:26PM +1100, Stephen Rothwell wrote:
> > diff --git a/arch/x86/kernel/irq.c b/arch/x86/kernel/irq.c
> > index 4417f49..23216f7 100644
> > --- a/arch/x86/kernel/irq.c
> > +++ b/arch/x86/kernel/irq.c
> > @@ -276,12 +276,14 @@ void smp_x86_platform_ipi(struct pt_regs *regs)
> >
> > EXPORT_SYMBOL_GPL(vector_used_by_percpu_irq);
> >
> > +#ifdef CONFIG_OF
> > unsigned int irq_create_of_mapping(struct device_node *controller,
> > const u32 *intspec, unsigned int intsize)
> > {
> > return intspec[0];
> > }
> > EXPORT_SYMBOL_GPL(irq_create_of_mapping);
> > +#endif
>
> Sigh, 'of' is the most misnamed Linux subsystem in history! 'CONFIG_OF_' always
> makes me ask 'config of what?' irq_create_of_mapping ditto.
>
> Why not OFW or OPENFIRMWARE?

That's not the half of it. Most of the new platforms using this code
don't have openfirmware either. This subsystem merely supports the
device tree data structure which originated with OpenFirmware, but has
been used heavily in non-ofw systems for many years now. Something
like dt_* would be more accurate.

The of_ prefixes are entirely historical. Off and on I consider doing
a mass rename, but I shy away from the scope of the work (plus nobody
has complained loud enough to make it a priority). If I were to do
such a thing it would probably be best to use a script to handle all
the renames, and I'd want to organize with Linus to get it committed
when it will have the least impact on everyone. Probably
immediately after a merge window closes.

BTW, I'm actually dropping the patch that added this function to x86
for this merge window since the patch that uses it isn't quite ready
yet. It will sit in my test tree for another cycle.

g.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/