diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2012-04-20 09:05:53 -0400 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2012-04-26 06:06:12 -0400 |
commit | 6bba2682c62e432eaf7b82f8ca182e8c73256e74 (patch) | |
tree | fc1a7072fb114e3a48bbfb7ffd894791f861208e /arch/blackfin | |
parent | a4cfc31da34eacafd9f6b16e149448bf0ef6d0b2 (diff) |
blackfin: 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>
Cc: Mike Frysinger <vapier@gentoo.org>
Link: http://lkml.kernel.org/r/20120420124557.717064871@linutronix.de
Diffstat (limited to 'arch/blackfin')
-rw-r--r-- | arch/blackfin/Kconfig | 1 | ||||
-rw-r--r-- | arch/blackfin/mach-common/smp.c | 19 |
2 files changed, 2 insertions, 18 deletions
diff --git a/arch/blackfin/Kconfig b/arch/blackfin/Kconfig index 373a6902d8fa..779b9c846fd7 100644 --- a/arch/blackfin/Kconfig +++ b/arch/blackfin/Kconfig | |||
@@ -37,6 +37,7 @@ config BLACKFIN | |||
37 | select GENERIC_IRQ_PROBE | 37 | select GENERIC_IRQ_PROBE |
38 | select IRQ_PER_CPU if SMP | 38 | select IRQ_PER_CPU if SMP |
39 | select HAVE_NMI_WATCHDOG if NMI_WATCHDOG | 39 | select HAVE_NMI_WATCHDOG if NMI_WATCHDOG |
40 | select GENERIC_SMP_IDLE_THREAD | ||
40 | 41 | ||
41 | config GENERIC_CSUM | 42 | config GENERIC_CSUM |
42 | def_bool y | 43 | def_bool y |
diff --git a/arch/blackfin/mach-common/smp.c b/arch/blackfin/mach-common/smp.c index d0cddd95b0dd..00bbe672b3b3 100644 --- a/arch/blackfin/mach-common/smp.c +++ b/arch/blackfin/mach-common/smp.c | |||
@@ -340,27 +340,10 @@ void smp_send_stop(void) | |||
340 | return; | 340 | return; |
341 | } | 341 | } |
342 | 342 | ||
343 | int __cpuinit __cpu_up(unsigned int cpu, struct task_struct *tidle) | 343 | int __cpuinit __cpu_up(unsigned int cpu, struct task_struct *idle) |
344 | { | 344 | { |
345 | int ret; | 345 | int ret; |
346 | struct blackfin_cpudata *ci = &per_cpu(cpu_data, cpu); | ||
347 | struct task_struct *idle = ci->idle; | ||
348 | 346 | ||
349 | if (idle) { | ||
350 | free_task(idle); | ||
351 | idle = NULL; | ||
352 | } | ||
353 | |||
354 | if (!idle) { | ||
355 | idle = fork_idle(cpu); | ||
356 | if (IS_ERR(idle)) { | ||
357 | printk(KERN_ERR "CPU%u: fork() failed\n", cpu); | ||
358 | return PTR_ERR(idle); | ||
359 | } | ||
360 | ci->idle = idle; | ||
361 | } else { | ||
362 | init_idle(idle, cpu); | ||
363 | } | ||
364 | secondary_stack = task_stack_page(idle) + THREAD_SIZE; | 347 | secondary_stack = task_stack_page(idle) + THREAD_SIZE; |
365 | 348 | ||
366 | ret = platform_boot_secondary(cpu, idle); | 349 | ret = platform_boot_secondary(cpu, idle); |