[PATCH][2/2] NX: Triple fault with 4k kernel mappings and PAE

From: Zwane Mwaikambo
Date: Sun Dec 05 2004 - 01:03:32 EST


Booting with NX, CONFIG_X86_PAE and CONFIG_DEBUG_PAGEALLOC or
mem=nopentium triple faults really early during boot as it appears to be
tripping over pages from PAGE_OFFSET -> PAGE_OFFSET + 0x100000 not being
marked as executable.

Signed-off-by: Zwane Mwaikambo <zwane@xxxxxxxxxxxxxxxx>

Index: linux-2.6.10-rc2/arch/i386/mm/init.c
===================================================================
RCS file: /home/cvsroot/linux-2.6.10-rc2/arch/i386/mm/init.c,v
retrieving revision 1.1.1.1
diff -u -p -B -r1.1.1.1 init.c
--- linux-2.6.10-rc2/arch/i386/mm/init.c 25 Nov 2004 19:45:32 -0000 1.1.1.1
+++ linux-2.6.10-rc2/arch/i386/mm/init.c 5 Dec 2004 05:41:19 -0000
@@ -126,7 +126,7 @@ static void __init page_table_range_init

static inline int is_kernel_text(unsigned long addr)
{
- if (addr >= (unsigned long)_stext && addr <= (unsigned long)__init_end)
+ if (addr >= PAGE_OFFSET && addr <= (unsigned long)__init_end)
return 1;
return 0;
}

-
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/