Re: [PATCH][resend] m68k,m68knommu: Do not include linux/hardirq.h in asm/irqflags.h

From: Geert Uytterhoeven
Date: Fri Oct 29 2010 - 12:32:05 EST


On Fri, Oct 29, 2010 at 16:06, Greg Ungerer <gerg@xxxxxxxxxxxx> wrote:
> Philippe DeMuyter noticed this build failure with Linus' current git
> tree. I think it is m68k clean too. If all are ok with it I'll
> pass it directly to Linus.

Sorry, I saw his patch before, but had no spare cycles left for testing.

Unfortunately that breaks CONFIG_MMU=y:

arch/m68k/include/asm/irqflags.h: In function âarch_local_irq_enableâ:
arch/m68k/include/asm/irqflags.h:43: error: implicit declaration of
function âhardirq_countâ

But if you protect the #include <linux/hardirq.h> by #ifdef
CONFIG_MMU, I'm happy with
it.

> m68k,m68knommu: Do not include linux/hardirq.h in asm/irqflags.h
>
> Recent changes to header files made kernel compilation for m68k/m68knommu
> fail with :
> ÂCC Â Â Âarch/m68knommu/kernel/asm-offsets.s
> In file included from /archives/linux/git/arch/m68k/include/asm/system.h:2,
> Â Â Â Â Â Â Â Â from include/linux/wait.h:25,
> Â Â Â Â Â Â Â Â from include/linux/mmzone.h:9,
> Â Â Â Â Â Â Â Â from include/linux/gfp.h:4,
> Â Â Â Â Â Â Â Â from include/linux/irq.h:20,
> Â Â Â Â Â Â Â Â from include/asm-generic/hardirq.h:12,
> Â Â Â Â Â Â Â Â from
> /archives/linux/git/arch/m68k/include/asm/hardirq_no.h:17,
> Â Â Â Â Â Â Â Â from /archives/linux/git/arch/m68k/include/asm/hardirq.h:2,
> Â Â Â Â Â Â Â Â from include/linux/hardirq.h:10,
> Â Â Â Â Â Â Â Â from /archives/linux/git/arch/m68k/include/asm/irqflags.h:5,
> Â Â Â Â Â Â Â Â from include/linux/irqflags.h:15,
> Â Â Â Â Â Â Â Â from include/linux/spinlock.h:53,
> Â Â Â Â Â Â Â Â from include/linux/seqlock.h:29,
> Â Â Â Â Â Â Â Â from include/linux/time.h:8,
> Â Â Â Â Â Â Â Â from include/linux/timex.h:56,
> Â Â Â Â Â Â Â Â from include/linux/sched.h:56,
> Â Â Â Â Â Â Â Â from arch/m68knommu/kernel/asm-offsets.c:12:
> /archives/linux/git/arch/m68k/include/asm/system_no.h: In function
> ÃâË__xchgÃââ:
> /archives/linux/git/arch/m68k/include/asm/system_no.h:79: error: implicit
> declaration of function ÃâËlocal_irq_saveÃââ
> /archives/linux/git/arch/m68k/include/asm/system_no.h:101: error: implicit
> declaration of function ÃâËlocal_irq_restoreÃââ
>
> Fix that
>
> Signed-off-by: Philippe De Muyter <phdm@xxxxxxxxx>
>
> ---
> diff --git a/arch/m68k/include/asm/irqflags.h
> b/arch/m68k/include/asm/irqflags.h
> index 4a5b284..38b414d 100644
> --- a/arch/m68k/include/asm/irqflags.h
> +++ b/arch/m68k/include/asm/irqflags.h
> @@ -2,7 +2,6 @@
> Â#define _M68K_IRQFLAGS_H
> Â#include <linux/types.h>
> -#include <linux/hardirq.h>
> Â#include <linux/preempt.h>
> Â#include <asm/thread_info.h>
> Â#include <asm/entry.h>

Gr{oetje,eeting}s,

            Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
             Â Â -- Linus Torvalds
--
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/