x86, mce: unify smp_thermal_interrupt, prepare mce_intel_64
authorHidetoshi Seto <seto.hidetoshi@jp.fujitsu.com>
Mon, 15 Jun 2009 08:24:09 +0000 (17:24 +0900)
committerH. Peter Anvin <hpa@zytor.com>
Tue, 16 Jun 2009 23:56:08 +0000 (16:56 -0700)
Break smp_thermal_interrupt() into two functions.

Signed-off-by: Hidetoshi Seto <seto.hidetoshi@jp.fujitsu.com>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
arch/x86/kernel/cpu/mcheck/mce_intel_64.c

index c548111d011b63d94e34965482eef0f0790eb6e0..a5232b2c4ca0e5c35a7617047ae86d0f2cc1a965 100644 (file)
 #include <asm/idle.h>
 #include <asm/therm_throt.h>
 
-asmlinkage void smp_thermal_interrupt(void)
+static void intel_thermal_interrupt(void)
 {
        __u64 msr_val;
 
-       ack_APIC_irq();
-
-       exit_idle();
-       irq_enter();
-
        rdmsrl(MSR_IA32_THERM_STATUS, msr_val);
        if (therm_throt_process(msr_val & THERM_STATUS_PROCHOT))
                mce_log_therm_throt_event(msr_val);
+}
 
+asmlinkage void smp_thermal_interrupt(void)
+{
+       ack_APIC_irq();
+       exit_idle();
+       irq_enter();
+       intel_thermal_interrupt();
        inc_irq_stat(irq_thermal_count);
        irq_exit();
 }