[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <tip-2ec9415c71a1ddad969602e690a9c848b81256b3@git.kernel.org>
Date: Sat, 28 Apr 2012 02:15:06 -0700
From: tip-bot for Thomas Gleixner <tglx@...utronix.de>
To: linux-tip-commits@...r.kernel.org
Cc: linux-kernel@...r.kernel.org, hpa@...or.com, mingo@...nel.org,
rusty@...tcorp.com.au, peterz@...radead.org,
srivatsa.bhat@...ux.vnet.ibm.com, paulmck@...ux.vnet.ibm.com,
mattst88@...il.com, tglx@...utronix.de
Subject: [tip:smp/hotplug] alpha: Use generic idle thread allocation
Commit-ID: 2ec9415c71a1ddad969602e690a9c848b81256b3
Gitweb: http://git.kernel.org/tip/2ec9415c71a1ddad969602e690a9c848b81256b3
Author: Thomas Gleixner <tglx@...utronix.de>
AuthorDate: Fri, 20 Apr 2012 13:05:55 +0000
Committer: Thomas Gleixner <tglx@...utronix.de>
CommitDate: Thu, 26 Apr 2012 12:06:12 +0200
alpha: Use generic idle thread allocation
Signed-off-by: Thomas Gleixner <tglx@...utronix.de>
Cc: Peter Zijlstra <peterz@...radead.org>
Cc: Rusty Russell <rusty@...tcorp.com.au>
Cc: Paul E. McKenney <paulmck@...ux.vnet.ibm.com>
Cc: Srivatsa S. Bhat <srivatsa.bhat@...ux.vnet.ibm.com>
Cc: Matt Turner <mattst88@...il.com>
Link: http://lkml.kernel.org/r/20120420124557.914631081@linutronix.de
---
arch/alpha/Kconfig | 1 +
arch/alpha/kernel/smp.c | 18 ++----------------
2 files changed, 3 insertions(+), 16 deletions(-)
diff --git a/arch/alpha/Kconfig b/arch/alpha/Kconfig
index 56a4df9..991b8bb 100644
--- a/arch/alpha/Kconfig
+++ b/arch/alpha/Kconfig
@@ -15,6 +15,7 @@ config ALPHA
select GENERIC_IRQ_SHOW
select ARCH_WANT_OPTIONAL_GPIOLIB
select ARCH_HAVE_NMI_SAFE_CMPXCHG
+ select GENERIC_SMP_IDLE_THREAD
help
The Alpha is a 64-bit general-purpose processor designed and
marketed by the Digital Equipment Corporation of blessed memory,
diff --git a/arch/alpha/kernel/smp.c b/arch/alpha/kernel/smp.c
index 68d3947..35ddc02 100644
--- a/arch/alpha/kernel/smp.c
+++ b/arch/alpha/kernel/smp.c
@@ -357,24 +357,10 @@ secondary_cpu_start(int cpuid, struct task_struct *idle)
* Bring one cpu online.
*/
static int __cpuinit
-smp_boot_one_cpu(int cpuid)
+smp_boot_one_cpu(int cpuid, struct task_struct *idle)
{
- struct task_struct *idle;
unsigned long timeout;
- /* Cook up an idler for this guy. Note that the address we
- give to kernel_thread is irrelevant -- it's going to start
- where HWRPB.CPU_restart says to start. But this gets all
- the other task-y sort of data structures set up like we
- wish. We can't use kernel_thread since we must avoid
- rescheduling the child. */
- idle = fork_idle(cpuid);
- if (IS_ERR(idle))
- panic("failed fork for CPU %d", cpuid);
-
- DBGS(("smp_boot_one_cpu: CPU %d state 0x%lx flags 0x%lx\n",
- cpuid, idle->state, idle->flags));
-
/* Signal the secondary to wait a moment. */
smp_secondary_alive = -1;
@@ -489,7 +475,7 @@ smp_prepare_boot_cpu(void)
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;
}
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists