From: Jan Beulich Date: Wed, 14 Jan 2009 12:28:51 +0000 (+0000) Subject: x86: avoid early crash in disable_local_APIC() X-Git-Tag: firefly_0821_release~15492^2~62 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=4a13ad0bd8869bb491c67918662f9b1852595af5;p=firefly-linux-kernel-4.4.55.git x86: avoid early crash in disable_local_APIC() E.g. when called due to an early panic. Signed-off-by: Jan Beulich Signed-off-by: Ingo Molnar --- diff --git a/arch/x86/kernel/apic.c b/arch/x86/kernel/apic.c index 0f830e4f5675..d19aa3aab62b 100644 --- a/arch/x86/kernel/apic.c +++ b/arch/x86/kernel/apic.c @@ -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(); /*