]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - arch/x86_64/kernel/smp.c
[PATCH] x86_64: Support alternative() in vsyscalls
[linux-2.6-omap-h63xx.git] / arch / x86_64 / kernel / smp.c
index 9db9dda161b40fe59df298406518bb4a867b0b61..6a666d248c1200a3c6caccc1eaeabbc3308fad81 100644 (file)
@@ -27,8 +27,7 @@
 #include <asm/mmu_context.h>
 #include <asm/proto.h>
 #include <asm/apicdef.h>
-
-#define __cpuinit __init
+#include <asm/idle.h>
 
 /*
  *     Smarter SMP flushing macros. 
@@ -452,13 +451,14 @@ int smp_call_function (void (*func) (void *info), void *info, int nonatomic,
 
 void smp_stop_cpu(void)
 {
+       unsigned long flags;
        /*
         * Remove this CPU:
         */
        cpu_clear(smp_processor_id(), cpu_online_map);
-       local_irq_disable();
+       local_irq_save(flags);
        disable_local_APIC();
-       local_irq_enable(); 
+       local_irq_restore(flags);
 }
 
 static void smp_really_stop_cpu(void *dummy)
@@ -513,6 +513,7 @@ asmlinkage void smp_call_function_interrupt(void)
        /*
         * At this point the info structure may be out of scope unless wait==1
         */
+       exit_idle();
        irq_enter();
        (*func)(info);
        irq_exit();