diff options
author | Jon Medhurst <tixy@linaro.org> | 2012-12-13 13:23:13 +0000 |
---|---|---|
committer | Jon Medhurst <tixy@linaro.org> | 2013-05-03 13:41:37 +0100 |
commit | ef9239cea25ffce561ffd5431f3491f0b72c1a94 (patch) | |
tree | ba3ec3e248bd461be28294752da4516e048703f4 /arch/arm/kernel/setup.c | |
parent | 397f7fafd39bdaddff2fb44835ae16149a956606 (diff) |
ARM: Enable selection of SMP operations at boot time
Add a new 'smp_init' hook to machine_desc so platforms can specify a
function to be used to setup smp ops instead of having a statically
defined value. The hook must return true when smp_ops are initialized.
If false the static mdesc->smp_ops will be used by default.
Add the definition of "bool" by including the linux/types.h file to
asm/mach/arch.h and make it self-contained.
Signed-off-by: Jon Medhurst <tixy@linaro.org>
Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Diffstat (limited to 'arch/arm/kernel/setup.c')
-rw-r--r-- | arch/arm/kernel/setup.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/arch/arm/kernel/setup.c b/arch/arm/kernel/setup.c index 234e339196c..bce757c97b2 100644 --- a/arch/arm/kernel/setup.c +++ b/arch/arm/kernel/setup.c @@ -787,7 +787,10 @@ void __init setup_arch(char **cmdline_p) arm_dt_init_cpu_maps(); #ifdef CONFIG_SMP if (is_smp()) { - smp_set_ops(mdesc->smp); + if (!mdesc->smp_init || !mdesc->smp_init()) { + if(mdesc->smp) + smp_set_ops(mdesc->smp); + } smp_init_cpus(); } #endif |