diff options
Diffstat (limited to 'arch/arm/mach-shmobile/platsmp.c')
| -rw-r--r-- | arch/arm/mach-shmobile/platsmp.c | 33 |
1 files changed, 20 insertions, 13 deletions
diff --git a/arch/arm/mach-shmobile/platsmp.c b/arch/arm/mach-shmobile/platsmp.c index ed8d2351915..9ebc246b8d7 100644 --- a/arch/arm/mach-shmobile/platsmp.c +++ b/arch/arm/mach-shmobile/platsmp.c @@ -11,21 +11,28 @@ * published by the Free Software Foundation. */ #include <linux/init.h> -#include <linux/smp.h> -#include <asm/hardware/gic.h> +#include <asm/cacheflush.h> +#include <asm/smp_plat.h> +#include <mach/common.h> -void __init shmobile_smp_init_cpus(unsigned int ncores) -{ - unsigned int i; +extern unsigned long shmobile_smp_fn[]; +extern unsigned long shmobile_smp_arg[]; +extern unsigned long shmobile_smp_mpidr[]; - if (ncores > nr_cpu_ids) { - pr_warn("SMP: %u cores greater than maximum (%u), clipping\n", - ncores, nr_cpu_ids); - ncores = nr_cpu_ids; - } +void shmobile_smp_hook(unsigned int cpu, unsigned long fn, unsigned long arg) +{ + shmobile_smp_fn[cpu] = 0; + flush_cache_all(); - for (i = 0; i < ncores; i++) - set_cpu_possible(i, true); + shmobile_smp_mpidr[cpu] = cpu_logical_map(cpu); + shmobile_smp_fn[cpu] = fn; + shmobile_smp_arg[cpu] = arg; + flush_cache_all(); +} - set_smp_cross_call(gic_raise_softirq); +#ifdef CONFIG_HOTPLUG_CPU +int shmobile_smp_cpu_disable(unsigned int cpu) +{ + return 0; /* Hotplug of any CPU is supported */ } +#endif |
