ARM: mach-shmobile: add shmobile_cpu_disable_any()
authorUlrich Hecht <ulrich.hecht@gmail.com>
Thu, 10 Jan 2013 10:16:43 +0000 (11:16 +0100)
committerSimon Horman <horms+renesas@verge.net.au>
Wed, 30 Jan 2013 04:07:59 +0000 (13:07 +0900)
Method to disable any core to be used on platforms where CPU0 does not
need special treatment.

Signed-off-by: Ulrich Hecht <ulrich.hecht@gmail.com>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
arch/arm/mach-shmobile/hotplug.c
arch/arm/mach-shmobile/include/mach/common.h

index b09a0bd..a1524e3 100644 (file)
@@ -56,6 +56,12 @@ int shmobile_cpu_disable(unsigned int cpu)
        return cpu == 0 ? -EPERM : 0;
 }
 
+int shmobile_cpu_disable_any(unsigned int cpu)
+{
+       cpumask_clear_cpu(cpu, &dead_cpus);
+       return 0;
+}
+
 int shmobile_cpu_is_dead(unsigned int cpu)
 {
        return cpumask_test_cpu(cpu, &dead_cpus);
index 64c0622..e48606d 100644 (file)
@@ -84,6 +84,7 @@ static inline int shmobile_cpuidle_init(void) { return 0; }
 
 extern void shmobile_cpu_die(unsigned int cpu);
 extern int shmobile_cpu_disable(unsigned int cpu);
+extern int shmobile_cpu_disable_any(unsigned int cpu);
 
 #ifdef CONFIG_HOTPLUG_CPU
 extern int shmobile_cpu_is_dead(unsigned int cpu);