]> git.openfabrics.org - ~emulex/infiniband.git/commitdiff
ARM: CPU hotplug: remove bug checks in platform_cpu_die()
authorRussell King <rmk+kernel@arm.linux.org.uk>
Tue, 30 Nov 2010 11:12:30 +0000 (11:12 +0000)
committerRussell King <rmk+kernel@arm.linux.org.uk>
Mon, 20 Dec 2010 15:09:10 +0000 (15:09 +0000)
platform_cpu_die() is entered from the CPU's own idle thread, which
can not be migrated to other CPUs.  Moreover, the 'cpu' argument
comes from the thread info, which will always be the 'current'
CPU.  So remove this useless bug check.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
arch/arm/mach-omap2/omap-hotplug.c
arch/arm/mach-realview/hotplug.c
arch/arm/mach-s5pv310/hotplug.c
arch/arm/mach-tegra/hotplug.c
arch/arm/mach-ux500/hotplug.c

index ace979d74bfcc99fd16d1199a0305d0c88e3cf41..4976b9393e49123ad04eaa8fabb15b7ca4357c99 100644 (file)
@@ -32,14 +32,6 @@ int platform_cpu_kill(unsigned int cpu)
  */
 void platform_cpu_die(unsigned int cpu)
 {
-       unsigned int this_cpu = hard_smp_processor_id();
-
-       if (cpu != this_cpu) {
-               pr_crit("platform_cpu_die running on %u, should be %u\n",
-                          this_cpu, cpu);
-               BUG();
-       }
-
        flush_cache_all();
        dsb();
 
index 7d58c16c83a7679e752a3ff3a37fe39e3804c180..e06572e6c4904138dfd4ed17466166eaf7521b36 100644 (file)
@@ -102,16 +102,6 @@ int platform_cpu_kill(unsigned int cpu)
  */
 void platform_cpu_die(unsigned int cpu)
 {
-#ifdef DEBUG
-       unsigned int this_cpu = hard_smp_processor_id();
-
-       if (cpu != this_cpu) {
-               printk(KERN_CRIT "Eek! platform_cpu_die running on %u, should be %u\n",
-                          this_cpu, cpu);
-               BUG();
-       }
-#endif
-
        /*
         * we're ready for shutdown now, so do it
         */
index d7be70ac753607791b7a62db200a88ac59adac2e..ea951ef6ea544fb91d0a9584f555370c90d1d8d9 100644 (file)
@@ -105,16 +105,6 @@ int platform_cpu_kill(unsigned int cpu)
  */
 void platform_cpu_die(unsigned int cpu)
 {
-#ifdef DEBUG
-       unsigned int this_cpu = hard_smp_processor_id();
-
-       if (cpu != this_cpu) {
-               printk(KERN_CRIT "Eek! platform_cpu_die running on %u, should be %u\n",
-                          this_cpu, cpu);
-               BUG();
-       }
-#endif
-
        /*
         * we're ready for shutdown now, so do it
         */
index ecaa41ce49767fa4b71b6af133fc6fc25b892bd5..a5eeb9126645da9806de475625d3d745859c6bbd 100644 (file)
@@ -101,16 +101,6 @@ int platform_cpu_kill(unsigned int cpu)
  */
 void platform_cpu_die(unsigned int cpu)
 {
-#ifdef DEBUG
-       unsigned int this_cpu = hard_smp_processor_id();
-
-       if (cpu != this_cpu) {
-               printk(KERN_CRIT "Eek! platform_cpu_die running on %u, should be %u\n",
-                          this_cpu, cpu);
-               BUG();
-       }
-#endif
-
        /*
         * we're ready for shutdown now, so do it
         */
index 7a4890b96e5cecbbfd04f242a2c99450584fa520..dd8037ebccf8b427e1b9fefa738a133f39082ef0 100644 (file)
@@ -45,16 +45,6 @@ int platform_cpu_kill(unsigned int cpu)
  */
 void platform_cpu_die(unsigned int cpu)
 {
-#ifdef DEBUG
-       unsigned int this_cpu = hard_smp_processor_id();
-
-       if (cpu != this_cpu) {
-               printk(KERN_CRIT "Eek! platform_cpu_die running on %u, should be %u\n",
-                          this_cpu, cpu);
-               BUG();
-       }
-#endif
-
        /* directly enter low power state, skipping secure registers */
        platform_do_lowpower(cpu);
 }