[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] Build problems: references to init_mm in pgtable*.h
Hi all, My normal xen .config will not build on recent linux-2.6-merge.hg trees. The problem is the include/asm-i386/mach-xen/asm/pgtable-2level.h and include/asm-i386/mach-xen/asm/pgtable-3level.h files, which reference "init_mm" without ever pulling in a definition of those files. Whether you see the problem or not depends on the .config; most files which include the pgtable*.h includes already pull in sched.h (which is where init_mm is declared), but not all do so. Trivial patch attached, but it's not necessarily the best solution as we don't want sched.h changes polluting mm .o's unnecessarily. --Stephen # HG changeset patch # User sct@xxxxxxxxxxxxxxxxxxxxx # Node ID c819204afd3829b65080f484e29bba4ef1130044 # Parent 9c37a7190588f04180851153bdcaaba9d566ed75 Builds are breaking with errors such as: In file included from include/asm/mach-xen/asm/pgtable.h:253, from include/asm/mach-xen/asm/desc.h:99, from include/asm/suspend.h:6, from include/linux/suspend.h:5, from kernel/power/main.c:11: include/asm/mach-xen/asm/pgtable-2level.h: In function âset_pte_atâ: include/asm/mach-xen/asm/pgtable-2level.h:21: error: dereferencing pointer to incomplete type include/asm/mach-xen/asm/pgtable-2level.h:21: error: âinit_mmâ undeclared (first use in this function) due to include/asm-i386/mach-xen/asm/pgtable-*level.h referencing "init_mm" without declaring it. We need to #include <sched.h> first to make this work. diff -r 9c37a7190588 -r c819204afd38 include/asm-i386/mach-xen/asm/pgtable-2level.h --- a/include/asm-i386/mach-xen/asm/pgtable-2level.h Tue Nov 29 14:34:01 2005 -0500 +++ b/include/asm-i386/mach-xen/asm/pgtable-2level.h Tue Nov 29 14:36:47 2005 -0500 @@ -2,6 +2,7 @@ #define _I386_PGTABLE_2LEVEL_H #include <asm-generic/pgtable-nopmd.h> +#include <linux/sched.h> #define pte_ERROR(e) \ printk("%s:%d: bad pte %08lx.\n", __FILE__, __LINE__, (e).pte_low) diff -r 9c37a7190588 -r c819204afd38 include/asm-i386/mach-xen/asm/pgtable-3level.h --- a/include/asm-i386/mach-xen/asm/pgtable-3level.h Tue Nov 29 14:34:01 2005 -0500 +++ b/include/asm-i386/mach-xen/asm/pgtable-3level.h Tue Nov 29 14:36:47 2005 -0500 @@ -2,6 +2,7 @@ #define _I386_PGTABLE_3LEVEL_H #include <asm-generic/pgtable-nopud.h> +#include <linux/sched.h> /* * Intel Physical Address Extension (PAE) Mode - three-level page _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |