summaryrefslogtreecommitdiffstats
path: root/arch/cris/arch-v32
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2012-04-20 13:05:53 +0000
committerThomas Gleixner <tglx@linutronix.de>2012-04-26 12:06:11 +0200
commita4cfc31da34eacafd9f6b16e149448bf0ef6d0b2 (patch)
tree29bf19eabf92361a71a1bf8fdebdfb0f3f4fbcf2 /arch/cris/arch-v32
parente80e7813cd772cf30597024b371e73df9736de8d (diff)
downloadblackbird-op-linux-a4cfc31da34eacafd9f6b16e149448bf0ef6d0b2.tar.gz
blackbird-op-linux-a4cfc31da34eacafd9f6b16e149448bf0ef6d0b2.zip
cris: Use generic idle thread allocation
Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rusty Russell <rusty@rustcorp.com.au> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Srivatsa S. Bhat <srivatsa.bhat@linux.vnet.ibm.com> Acked-by: Jesper Nilsson <jesper.nilsson@axis.com> Link: http://lkml.kernel.org/r/20120420124557.789657793@linutronix.de
Diffstat (limited to 'arch/cris/arch-v32')
-rw-r--r--arch/cris/arch-v32/kernel/smp.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/arch/cris/arch-v32/kernel/smp.c b/arch/cris/arch-v32/kernel/smp.c
index 125ee2d7bc87..ebe2cb30bd11 100644
--- a/arch/cris/arch-v32/kernel/smp.c
+++ b/arch/cris/arch-v32/kernel/smp.c
@@ -108,17 +108,12 @@ void __init smp_cpus_done(unsigned int max_cpus)
/* Bring one cpu online.*/
static int __init
-smp_boot_one_cpu(int cpuid)
+smp_boot_one_cpu(int cpuid, struct task_struct idle)
{
unsigned timeout;
- struct task_struct *idle;
cpumask_t cpu_mask;
cpumask_clear(&cpu_mask);
- idle = fork_idle(cpuid);
- if (IS_ERR(idle))
- panic("SMP: fork failed for CPU:%d", cpuid);
-
task_thread_info(idle)->cpu = cpuid;
/* Information to the CPU that is about to boot */
@@ -142,9 +137,6 @@ smp_boot_one_cpu(int cpuid)
barrier();
}
- put_task_struct(idle);
- idle = NULL;
-
printk(KERN_CRIT "SMP: CPU:%d is stuck.\n", cpuid);
return -1;
}
@@ -209,7 +201,7 @@ unsigned long cache_decay_ticks = 1;
int __cpuinit __cpu_up(unsigned int cpu, struct task_struct *tidle)
{
- smp_boot_one_cpu(cpu);
+ smp_boot_one_cpu(cpu, tidle);
return cpu_online(cpu) ? 0 : -ENOSYS;
}
OpenPOWER on IntegriCloud