vserver 1.9.3
[linux-2.6.git] / arch / sh / kernel / smp.c
index adb8eae..6ff83ed 100644 (file)
@@ -26,7 +26,6 @@
 #include <asm/atomic.h>
 #include <asm/processor.h>
 #include <asm/system.h>
-#include <asm/hardirq.h>
 #include <asm/mmu_context.h>
 #include <asm/smp.h>
 
@@ -98,19 +97,12 @@ void __devinit smp_prepare_boot_cpu(void)
 int __cpu_up(unsigned int cpu)
 {
        struct task_struct *tsk;
-       struct pt_regs regs;
 
-       memset(&regs, 0, sizeof(struct pt_regs));
-       tsk = copy_process(CLONE_VM | CLONE_IDLETASK, 0, &regs, 0, 0, 0);
+       tsk = fork_idle(cpu);
 
        if (IS_ERR(tsk))
                panic("Failed forking idle task for cpu %d\n", cpu);
        
-       wake_up_forked_process(tsk);
-
-       init_idle(tsk, cpu);
-       unhash_process(tsk);
-       
        tsk->thread_info->cpu = cpu;
 
        cpu_set(cpu, cpu_online_map);