diff options
author | Borislav Petkov <borislav.petkov@amd.com> | 2009-10-16 06:31:33 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-10-16 08:46:50 -0400 |
commit | b33a6363649f0ff83ec81597ea7fe7e688f973cb (patch) | |
tree | 9ed8e308bfddb01eaf7e5217d0d4e0274b38aa7b /arch/x86 | |
parent | 5e09954a9acc3b435ffe318b95afd3c02fae069f (diff) |
x86, mce: Add a global MCE init helper
Add an early initcall (pre SMP) which sets up global MCE
functionality.
Signed-off-by: Borislav Petkov <borislav.petkov@amd.com>
Cc: Andi Kleen <andi@firstfloor.org>
LKML-Reference: <1255689093-26921-2-git-send-email-borislav.petkov@amd.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86')
-rw-r--r-- | arch/x86/kernel/cpu/mcheck/mce.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/arch/x86/kernel/cpu/mcheck/mce.c b/arch/x86/kernel/cpu/mcheck/mce.c index 68d968e69b13..80801705edd7 100644 --- a/arch/x86/kernel/cpu/mcheck/mce.c +++ b/arch/x86/kernel/cpu/mcheck/mce.c | |||
@@ -1436,8 +1436,6 @@ void __cpuinit mcheck_cpu_init(struct cpuinfo_x86 *c) | |||
1436 | __mcheck_cpu_init_timer(); | 1436 | __mcheck_cpu_init_timer(); |
1437 | INIT_WORK(&__get_cpu_var(mce_work), mce_process_work); | 1437 | INIT_WORK(&__get_cpu_var(mce_work), mce_process_work); |
1438 | 1438 | ||
1439 | if (raw_smp_processor_id() == 0) | ||
1440 | atomic_notifier_chain_register(&x86_mce_decoder_chain, &mce_dec_nb); | ||
1441 | } | 1439 | } |
1442 | 1440 | ||
1443 | /* | 1441 | /* |
@@ -1657,6 +1655,14 @@ static int __init mcheck_enable(char *str) | |||
1657 | } | 1655 | } |
1658 | __setup("mce", mcheck_enable); | 1656 | __setup("mce", mcheck_enable); |
1659 | 1657 | ||
1658 | static int __init mcheck_init(void) | ||
1659 | { | ||
1660 | atomic_notifier_chain_register(&x86_mce_decoder_chain, &mce_dec_nb); | ||
1661 | |||
1662 | return 0; | ||
1663 | } | ||
1664 | early_initcall(mcheck_init); | ||
1665 | |||
1660 | /* | 1666 | /* |
1661 | * Sysfs support | 1667 | * Sysfs support |
1662 | */ | 1668 | */ |