lkml.org 
[lkml]   [2007]   [Jun]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectUML - Compilation problem on 2.6.22-rc4
Hello,
I ran into some compilations problems with UML on the 2.6.22-rc4 kernel.
The problem turns up because "paravirt.h" is included in a couple of
headers in asm-i386 without being protected by a "#ifdef CONFIG_PARAVIRT".

I've attached a patch to fix this (i.e. UML compiles and runs fine for
me with these changes). I don't know if this is sufficient for all cases
though (most other uses of the #ifdef include a lengthy #else).

Please keep me in CC as I'm not on the mailing list.

-- Arun
diff -uprN -X /usr/src/linux-2.6.22-rc4/Documentation/dontdiff /usr/src/linux-2.6.22-rc4/include/asm-i386/highmem.h linux-2.6.22-rc4-uml-fix/include/asm-i386/highmem.h
--- /usr/src/linux-2.6.22-rc4/include/asm-i386/highmem.h 2007-06-14 12:12:58.000000000 +0530
+++ linux-2.6.22-rc4-uml-fix/include/asm-i386/highmem.h 2007-06-15 11:34:10.000000000 +0530
@@ -24,7 +24,9 @@
#include <linux/threads.h>
#include <asm/kmap_types.h>
#include <asm/tlbflush.h>
+#ifdef CONFIG_PARAVIRT
#include <asm/paravirt.h>
+#endif

/* declarations for highmem.c */
extern unsigned long highstart_pfn, highend_pfn;
diff -uprN -X /usr/src/linux-2.6.22-rc4/Documentation/dontdiff /usr/src/linux-2.6.22-rc4/include/asm-i386/mmu_context.h linux-2.6.22-rc4-uml-fix/include/asm-i386/mmu_context.h
--- /usr/src/linux-2.6.22-rc4/include/asm-i386/mmu_context.h 2007-06-14 12:12:58.000000000 +0530
+++ linux-2.6.22-rc4-uml-fix/include/asm-i386/mmu_context.h 2007-06-15 11:34:24.000000000 +0530
@@ -5,8 +5,9 @@
#include <asm/atomic.h>
#include <asm/pgalloc.h>
#include <asm/tlbflush.h>
+#ifdef CONFIG_PARAVIRT
#include <asm/paravirt.h>
-#ifndef CONFIG_PARAVIRT
+#else
#include <asm-generic/mm_hooks.h>

static inline void paravirt_activate_mm(struct mm_struct *prev,
\
 
 \ /
  Last update: 2007-06-15 08:59    [W:0.023 / U:0.400 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site