diff options
| author | Andi Kleen <ak@suse.de> | 2005-11-05 11:25:54 -0500 |
|---|---|---|
| committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-11-14 22:55:17 -0500 |
| commit | e583538f077d5f70191670b47a046ba436ec3428 (patch) | |
| tree | 576298f190ce8a4f321bb84efce2ace41aa12194 | |
| parent | b0bd35e622ffbda2c01dc67a0381c6a18817a29a (diff) | |
[PATCH] x86_64: Log machine checks from boot on Intel systems
The logging for boot errors was turned off because it was broken
on some AMD systems. But give Intel EM64T systems a chance because they are
supposed to be correct there.
The advantage is that there is a chance to actually log uncorrected
machine checks after the reset.
Signed-off-by: Andi Kleen <ak@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
| -rw-r--r-- | Documentation/x86_64/boot-options.txt | 6 | ||||
| -rw-r--r-- | arch/x86_64/kernel/mce.c | 14 |
2 files changed, 13 insertions, 7 deletions
diff --git a/Documentation/x86_64/boot-options.txt b/Documentation/x86_64/boot-options.txt index a83139692cdf..aaabb5883ab8 100644 --- a/Documentation/x86_64/boot-options.txt +++ b/Documentation/x86_64/boot-options.txt | |||
| @@ -7,10 +7,12 @@ Machine check | |||
| 7 | 7 | ||
| 8 | mce=off disable machine check | 8 | mce=off disable machine check |
| 9 | mce=bootlog Enable logging of machine checks left over from booting. | 9 | mce=bootlog Enable logging of machine checks left over from booting. |
| 10 | Disabled by default because some BIOS leave bogus ones. | 10 | Disabled by default on AMD because some BIOS leave bogus ones. |
| 11 | If your BIOS doesn't do that it's a good idea to enable though | 11 | If your BIOS doesn't do that it's a good idea to enable though |
| 12 | to make sure you log even machine check events that result | 12 | to make sure you log even machine check events that result |
| 13 | in a reboot. | 13 | in a reboot. On Intel systems it is enabled by default. |
| 14 | mce=nobootlog | ||
| 15 | Disable boot machine check logging. | ||
| 14 | mce=tolerancelevel (number) | 16 | mce=tolerancelevel (number) |
| 15 | 0: always panic, 1: panic if deadlock possible, | 17 | 0: always panic, 1: panic if deadlock possible, |
| 16 | 2: try to avoid panic, 3: never panic or exit (for testing) | 18 | 2: try to avoid panic, 3: never panic or exit (for testing) |
diff --git a/arch/x86_64/kernel/mce.c b/arch/x86_64/kernel/mce.c index cf8a76f0f47e..183dc6105429 100644 --- a/arch/x86_64/kernel/mce.c +++ b/arch/x86_64/kernel/mce.c | |||
| @@ -37,7 +37,7 @@ static unsigned long bank[NR_BANKS] = { [0 ... NR_BANKS-1] = ~0UL }; | |||
| 37 | static unsigned long console_logged; | 37 | static unsigned long console_logged; |
| 38 | static int notify_user; | 38 | static int notify_user; |
| 39 | static int rip_msr; | 39 | static int rip_msr; |
| 40 | static int mce_bootlog; | 40 | static int mce_bootlog = 1; |
| 41 | 41 | ||
| 42 | /* | 42 | /* |
| 43 | * Lockless MCE logging infrastructure. | 43 | * Lockless MCE logging infrastructure. |
| @@ -347,7 +347,11 @@ static void __cpuinit mce_cpu_quirks(struct cpuinfo_x86 *c) | |||
| 347 | /* disable GART TBL walk error reporting, which trips off | 347 | /* disable GART TBL walk error reporting, which trips off |
| 348 | incorrectly with the IOMMU & 3ware & Cerberus. */ | 348 | incorrectly with the IOMMU & 3ware & Cerberus. */ |
| 349 | clear_bit(10, &bank[4]); | 349 | clear_bit(10, &bank[4]); |
| 350 | /* Lots of broken BIOS around that don't clear them | ||
| 351 | by default and leave crap in there. Don't log. */ | ||
| 352 | mce_bootlog = 0; | ||
| 350 | } | 353 | } |
| 354 | |||
| 351 | } | 355 | } |
| 352 | 356 | ||
| 353 | static void __cpuinit mce_cpu_features(struct cpuinfo_x86 *c) | 357 | static void __cpuinit mce_cpu_features(struct cpuinfo_x86 *c) |
| @@ -498,16 +502,16 @@ static int __init mcheck_disable(char *str) | |||
| 498 | /* mce=off disables machine check. Note you can reenable it later | 502 | /* mce=off disables machine check. Note you can reenable it later |
| 499 | using sysfs. | 503 | using sysfs. |
| 500 | mce=TOLERANCELEVEL (number, see above) | 504 | mce=TOLERANCELEVEL (number, see above) |
| 501 | mce=bootlog Log MCEs from before booting. Disabled by default to work | 505 | mce=bootlog Log MCEs from before booting. Disabled by default on AMD. |
| 502 | around buggy BIOS that leave bogus MCEs. */ | 506 | mce=nobootlog Don't log MCEs from before booting. */ |
| 503 | static int __init mcheck_enable(char *str) | 507 | static int __init mcheck_enable(char *str) |
| 504 | { | 508 | { |
| 505 | if (*str == '=') | 509 | if (*str == '=') |
| 506 | str++; | 510 | str++; |
| 507 | if (!strcmp(str, "off")) | 511 | if (!strcmp(str, "off")) |
| 508 | mce_dont_init = 1; | 512 | mce_dont_init = 1; |
| 509 | else if (!strcmp(str, "bootlog")) | 513 | else if (!strcmp(str, "bootlog") || !strcmp(str,"nobootlog")) |
| 510 | mce_bootlog = 1; | 514 | mce_bootlog = str[0] == 'b'; |
| 511 | else if (isdigit(str[0])) | 515 | else if (isdigit(str[0])) |
| 512 | get_option(&str, &tolerant); | 516 | get_option(&str, &tolerant); |
| 513 | else | 517 | else |
