diff options
author | Jan Beulich <JBeulich@suse.com> | 2011-09-28 11:56:51 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2011-09-28 13:04:48 -0400 |
commit | e05139f2569ecf699b229a6473a86cdffed62956 (patch) | |
tree | 58882e5b22d9f309c8748f72d25e92ee8de883b7 /arch | |
parent | a102a9ece5489e1718cd7543aa079082450ac3a2 (diff) |
x86-64: Don't apply destructive erratum workaround on unaffected CPUs
Erratum 93 applies to AMD K8 CPUs only, and its workaround
(forcing the upper 32 bits of %rip to all get set under certain
conditions) is actually getting in the way of analyzing page
faults occurring during EFI physical mode runtime calls (in
particular the page table walk shown is completely unrelated to
the actual fault). This is because typically EFI runtime code
lives in the space between 2G and 4G, which - modulo the above
manipulation - is likely to overlap with the kernel or modules
area.
While even for the other errata workarounds their taking effect
could be limited to just the affected CPUs, none of them appears
to be destructive, and they're generally getting called only
outside of performance critical paths, so they're being left
untouched.
Signed-off-by: Jan Beulich <jbeulich@suse.com>
Link: http://lkml.kernel.org/r/4E835FE30200007800058464@nat28.tlf.novell.com
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/x86/mm/fault.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/arch/x86/mm/fault.c b/arch/x86/mm/fault.c index 0d17c8c50acd..9c7378df740a 100644 --- a/arch/x86/mm/fault.c +++ b/arch/x86/mm/fault.c | |||
@@ -420,12 +420,14 @@ static noinline __kprobes int vmalloc_fault(unsigned long address) | |||
420 | return 0; | 420 | return 0; |
421 | } | 421 | } |
422 | 422 | ||
423 | #ifdef CONFIG_CPU_SUP_AMD | ||
423 | static const char errata93_warning[] = | 424 | static const char errata93_warning[] = |
424 | KERN_ERR | 425 | KERN_ERR |
425 | "******* Your BIOS seems to not contain a fix for K8 errata #93\n" | 426 | "******* Your BIOS seems to not contain a fix for K8 errata #93\n" |
426 | "******* Working around it, but it may cause SEGVs or burn power.\n" | 427 | "******* Working around it, but it may cause SEGVs or burn power.\n" |
427 | "******* Please consider a BIOS update.\n" | 428 | "******* Please consider a BIOS update.\n" |
428 | "******* Disabling USB legacy in the BIOS may also help.\n"; | 429 | "******* Disabling USB legacy in the BIOS may also help.\n"; |
430 | #endif | ||
429 | 431 | ||
430 | /* | 432 | /* |
431 | * No vm86 mode in 64-bit mode: | 433 | * No vm86 mode in 64-bit mode: |
@@ -505,7 +507,11 @@ bad: | |||
505 | */ | 507 | */ |
506 | static int is_errata93(struct pt_regs *regs, unsigned long address) | 508 | static int is_errata93(struct pt_regs *regs, unsigned long address) |
507 | { | 509 | { |
508 | #ifdef CONFIG_X86_64 | 510 | #if defined(CONFIG_X86_64) && defined(CONFIG_CPU_SUP_AMD) |
511 | if (boot_cpu_data.x86_vendor != X86_VENDOR_AMD | ||
512 | || boot_cpu_data.x86 != 0xf) | ||
513 | return 0; | ||
514 | |||
509 | if (address != regs->ip) | 515 | if (address != regs->ip) |
510 | return 0; | 516 | return 0; |
511 | 517 | ||