diff --git a/arch/x86_64/kernel/mce.c b/arch/x86_64/kernel/mce.c index b8f28ebdce261656e4141d4eec6849200d91cce0..13a2eada6c9520e2e32d38e278f6e57e8c06cd53 100644 --- a/arch/x86_64/kernel/mce.c +++ b/arch/x86_64/kernel/mce.c @@ -24,6 +24,7 @@ #include #include #include +#include #define MISC_MCELOG_MINOR 227 #define NR_BANKS 6 @@ -178,7 +179,7 @@ void do_machine_check(struct pt_regs * regs, long error_code) return; memset(&m, 0, sizeof(struct mce)); - m.cpu = hard_smp_processor_id(); + m.cpu = safe_smp_processor_id(); rdmsrl(MSR_IA32_MCG_STATUS, m.mcgstatus); if (!(m.mcgstatus & MCG_STATUS_RIPV)) kill_it = 1;