Re: GIT head no longer boots on x86-64

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Ingo Molnar
Date: Wednesday, October 15, 2008 - 4:51 am

* Alan Cox <alan@lxorguk.ukuu.org.uk> wrote:


Queued the fix below up in tip/x86/urgent for a merge to Linus later 
today. Thanks!

	Ingo

------------------>
From 5870942537422066655816e971629aa729c023d8 Mon Sep 17 00:00:00 2001
From: Jiri Slaby <jirislaby@gmail.com>
Date: Mon, 13 Oct 2008 17:11:33 +0200
Subject: [PATCH] x86: fix CONFIG_DEBUG_VIRTUAL=y boot crash on x86-64

Alan reported a bootup crash in the module loader:


SMP kernel is running on UP, in such a case the module .text
is patched to use UP locks before the module is added to the modules
list and it thinks there are no valid data at that place while
patching.

Also the !is_module_address(addr) test is useless now.

Reported-by: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Tested-by: Alan Cox <alan@lxorguk.ukuu.org.uk>
---
 include/linux/mm.h |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/include/linux/mm.h b/include/linux/mm.h
index c61ba10..45772fd 100644
--- a/include/linux/mm.h
+++ b/include/linux/mm.h
@@ -267,6 +267,10 @@ static inline int is_vmalloc_addr(const void *x)
 #ifdef CONFIG_MMU
 	unsigned long addr = (unsigned long)x;
 
+#ifdef CONFIG_X86_64
+	if (addr >= MODULES_VADDR && addr < MODULES_END)
+		return 1;
+#endif
 	return addr >= VMALLOC_START && addr < VMALLOC_END;
 #else
 	return 0;
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
GIT head no longer boots on x86-64, Alan Cox, (Mon Oct 13, 2:23 am)
Re: GIT head no longer boots on x86-64, Jiri Slaby, (Mon Oct 13, 3:13 am)
Re: GIT head no longer boots on x86-64, Alan Cox, (Mon Oct 13, 3:20 am)
Re: GIT head no longer boots on x86-64, Jiri Slaby, (Mon Oct 13, 3:56 am)
Re: GIT head no longer boots on x86-64, Alan Cox, (Mon Oct 13, 6:35 am)
Re: GIT head no longer boots on x86-64, Linus Torvalds, (Mon Oct 13, 7:45 am)
Re: GIT head no longer boots on x86-64, Jiri Slaby, (Mon Oct 13, 7:50 am)
Re: GIT head no longer boots on x86-64, Linus Torvalds, (Mon Oct 13, 8:03 am)
Re: GIT head no longer boots on x86-64, Jiri Slaby, (Mon Oct 13, 8:11 am)
Re: GIT head no longer boots on x86-64, Alan Cox, (Mon Oct 13, 8:47 am)
Re: GIT head no longer boots on x86-64, Ingo Molnar, (Wed Oct 15, 4:51 am)
Re: GIT head no longer boots on x86-64, Jiri Slaby, (Wed Oct 15, 6:19 am)
Re: GIT head no longer boots on x86-64, Linus Torvalds, (Wed Oct 15, 8:06 am)
Re: GIT head no longer boots on x86-64, Jiri Slaby, (Wed Oct 15, 8:33 am)
Re: GIT head no longer boots on x86-64, Linus Torvalds, (Wed Oct 15, 8:35 am)
Re: GIT head no longer boots on x86-64, Linus Torvalds, (Wed Oct 15, 9:01 am)
Re: GIT head no longer boots on x86-64, Arjan van de Ven, (Wed Oct 15, 1:31 pm)
Re: GIT head no longer boots on x86-64, H. Peter Anvin, (Thu Oct 16, 3:31 am)