xen/arm: Clean up identify processor call for secondary cpus
authorJulien Grall <julien.grall@linaro.org>
Mon, 29 Jul 2013 13:42:13 +0000 (14:42 +0100)
committerIan Campbell <ian.campbell@citrix.com>
Mon, 29 Jul 2013 15:54:48 +0000 (16:54 +0100)
The smp_processor_id() is set at the beginning of start_secondary. We don't
need to compute ourself the offset of the cpu data.

Signed-off-by: Julien Grall <julien.grall@linaro.org>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
xen/arch/arm/smpboot.c

index 58951782135983c3cc3c82be1f2cc01e9e230d8a..b6aea63e18f2f142de098f94f76790fe075d9d35 100644 (file)
@@ -137,15 +137,13 @@ void __cpuinit start_secondary(unsigned long boot_phys_offset,
                                unsigned long fdt_paddr,
                                unsigned long cpuid)
 {
-    struct cpuinfo_arm *c = cpu_data + cpuid;
-
     memset(get_cpu_info(), 0, sizeof (struct cpu_info));
 
     /* TODO: handle boards where CPUIDs are not contiguous */
     set_processor_id(cpuid);
 
-    *c = boot_cpu_data;
-    identify_cpu(c);
+    current_cpu_data = boot_cpu_data;
+    identify_cpu(&current_cpu_data);
 
     init_traps();