x86: avoid early crash in disable_local_APIC()
authorJan Beulich <jbeulich@novell.com>
Wed, 14 Jan 2009 12:28:51 +0000 (12:28 +0000)
committerIngo Molnar <mingo@elte.hu>
Thu, 15 Jan 2009 11:04:40 +0000 (12:04 +0100)
E.g. when called due to an early panic.

Signed-off-by: Jan Beulich <jbeulich@novell.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
arch/x86/kernel/apic.c

index c3dd64f..38d6aab 100644 (file)
@@ -895,6 +895,10 @@ void disable_local_APIC(void)
 {
        unsigned int value;
 
+       /* APIC hasn't been mapped yet */
+       if (!apic_phys)
+               return;
+
        clear_local_APIC();
 
        /*