Commit 64f520d1 authored by Andi Kleen's avatar Andi Kleen Committed by Linus Torvalds

[PATCH] x86_64: fix early oops printing

Fix early oopses

Without this very early oopses crash recursively while trying
to figure out the current CPU number.

Based on a patch by James Cleverdon.
Signed-off-by: default avatarAndi Kleen <ak@suse.de>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 68107b27
......@@ -109,6 +109,11 @@ static inline int x86_apicid_to_cpu(u8 apicid)
if (x86_cpu_to_apicid[0] == BAD_APICID)
return 0;
/* No entries in x86_cpu_to_apicid? Either no MPS|ACPI,
* or called too early. Either way, we must be CPU 0. */
if (x86_cpu_to_apicid[0] == BAD_APICID)
return 0;
return -1;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment