diff options
| author | Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com> | 2009-04-24 03:22:08 -0400 |
|---|---|---|
| committer | Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com> | 2009-05-08 18:55:10 -0400 |
| commit | b80119bb35a49a4e8dbfb9708872adfd5cf38dee (patch) | |
| tree | 75b77e0613fc02032beed1871c57000ec864d466 | |
| parent | 6cac5a924668a56c7ccefc345805f1fe0536a90e (diff) | |
xen/x86-64: clean up warnings about IST-using traps
Ignore known IST-using traps. Aside from the debugger traps, they're
low-level faults which Xen will handle for us, so the kernel needn't
worry about them. Keep warning in case unknown trap starts using IST.
Impact: suppress spurious warnings
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
| -rw-r--r-- | arch/x86/xen/enlighten.c | 22 |
1 files changed, 20 insertions, 2 deletions
diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c index 7566e13c0cac..e9df942aa143 100644 --- a/arch/x86/xen/enlighten.c +++ b/arch/x86/xen/enlighten.c | |||
| @@ -439,14 +439,32 @@ static int cvt_gate_to_trap(int vector, const gate_desc *val, | |||
| 439 | 439 | ||
| 440 | addr = gate_offset(*val); | 440 | addr = gate_offset(*val); |
| 441 | #ifdef CONFIG_X86_64 | 441 | #ifdef CONFIG_X86_64 |
| 442 | /* | ||
| 443 | * Look for known traps using IST, and substitute them | ||
| 444 | * appropriately. The debugger ones are the only ones we care | ||
| 445 | * about. Xen will handle faults like double_fault and | ||
| 446 | * machine_check, so we should never see them. Warn if | ||
| 447 | * there's an unexpected IST-using fault handler. | ||
| 448 | */ | ||
| 442 | if (addr == (unsigned long)debug) | 449 | if (addr == (unsigned long)debug) |
| 443 | addr = (unsigned long)xen_debug; | 450 | addr = (unsigned long)xen_debug; |
| 444 | else if (addr == (unsigned long)int3) | 451 | else if (addr == (unsigned long)int3) |
| 445 | addr = (unsigned long)xen_int3; | 452 | addr = (unsigned long)xen_int3; |
| 446 | else if (addr == (unsigned long)stack_segment) | 453 | else if (addr == (unsigned long)stack_segment) |
| 447 | addr = (unsigned long)xen_stack_segment; | 454 | addr = (unsigned long)xen_stack_segment; |
| 448 | else | 455 | else if (addr == (unsigned long)double_fault || |
| 449 | WARN_ON(val->ist != 0); | 456 | addr == (unsigned long)nmi) { |
| 457 | /* Don't need to handle these */ | ||
| 458 | return 0; | ||
| 459 | #ifdef CONFIG_X86_MCE | ||
| 460 | } else if (addr == (unsigned long)machine_check) { | ||
| 461 | return 0; | ||
| 462 | #endif | ||
| 463 | } else { | ||
| 464 | /* Some other trap using IST? */ | ||
| 465 | if (WARN_ON(val->ist != 0)) | ||
| 466 | return 0; | ||
| 467 | } | ||
| 450 | #endif /* CONFIG_X86_64 */ | 468 | #endif /* CONFIG_X86_64 */ |
| 451 | info->address = addr; | 469 | info->address = addr; |
| 452 | 470 | ||
