Re: include/linux/irq.h:452: error: implicit declaration offunction 'cpu_to_node'

From: Alexey Dobriyan
Date: Mon Feb 09 2009 - 15:30:45 EST


On Wed, Jan 21, 2009 at 03:38:25PM -0800, Mike Travis wrote:
> Alexey Dobriyan wrote:
> > On mips-malta:
> >
> > CC arch/mips/mti-malta/malta-int.o
> > In file included from arch/mips/mti-malta/malta-int.c:25:
> > include/linux/irq.h: In function 'init_alloc_desc_masks':
> > include/linux/irq.h:452: error: implicit declaration of function 'cpu_to_node'
> > include/linux/irq.h:454: error: 'GFP_ATOMIC' undeclared (first use in this function)
> >
> > I _think_ init_alloc_desc_masks() should be made out of line to fix this.
>
> Hi Alexey,
>
> Does adding #include <linux/slab.h> fix the error? If so, I can add this to
> linux/irq.h.
>
> The primary reason it's inline is that unless CONFIG_CPUMASK_OFFSTACK=y, then the
> entire routine is a NOP which optimizes out more completely as an inline function.

linux/slab.h helps.
--
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/