x86: drop hard_smp_procssor_id()
authorJan Beulich <jbeulich@suse.com>
Mon, 16 Nov 2015 12:12:20 +0000 (13:12 +0100)
committerJan Beulich <jbeulich@suse.com>
Mon, 16 Nov 2015 12:12:20 +0000 (13:12 +0100)
... and use what it aliased to directly.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
xen/arch/x86/cpu/common.c
xen/arch/x86/cpu/mcheck/mce.c
xen/arch/x86/io_apic.c
xen/arch/x86/smp.c
xen/arch/x86/smpboot.c
xen/include/asm-x86/smp.h

index a111ed6ac1a11b605655ffe38f19e93008c4e96c..e60929daa2ce57686f508fefc44f2b381f62c2ad 100644 (file)
@@ -162,13 +162,13 @@ static inline u32 _phys_pkg_id(u32 cpuid_apic, int index_msb)
 /*
  * cpuid returns the value latched in the HW at reset, not the APIC ID
  * register's value.  For any box whose BIOS changes APIC IDs, like
- * clustered APIC systems, we must use hard_smp_processor_id.
+ * clustered APIC systems, we must use get_apic_id().
  *
  * See Intel's IA-32 SW Dev's Manual Vol2 under CPUID.
  */
 static inline u32 phys_pkg_id(u32 cpuid_apic, int index_msb)
 {
-       return _phys_pkg_id(hard_smp_processor_id(), index_msb);
+       return _phys_pkg_id(get_apic_id(), index_msb);
 }
 
 /* Do minimum CPU detection early.
index 08cd3f2cdd74b7b8ed1daff0c9dc95498b61cbd7..d746d0e361bc920eb528899ffe529afd53c33746 100644 (file)
@@ -20,6 +20,7 @@
 
 #include <asm/processor.h>
 #include <asm/system.h>
+#include <asm/apic.h>
 #include <asm/msr.h>
 #include <asm/p2m.h>
 
@@ -980,7 +981,7 @@ static void do_mc_get_cpu_info(void *v)
         cpuid(1, &junk, &ebx, &junk, &junk);
         xcp->mc_clusterid = (ebx >> 24) & 0xff;
     } else
-        xcp->mc_clusterid = hard_smp_processor_id();
+        xcp->mc_clusterid = get_apic_id();
 }
 
 
index 6a71cef7f8d78024bb551cf5030b50ed28147604..11a0e5d714712d3d05eb494996950c09744a146d 100644 (file)
@@ -1843,7 +1843,7 @@ static void __init unlock_ExtINT_logic(void)
 
     entry1.dest_mode = 0;                      /* physical delivery */
     entry1.mask = 0;                   /* unmask IRQ now */
-    SET_DEST(entry1, physical, hard_smp_processor_id());
+    SET_DEST(entry1, physical, get_apic_id());
     entry1.delivery_mode = dest_ExtINT;
     entry1.polarity = entry0.polarity;
     entry1.trigger = 0;
index 8caa0bce3383fc1da87cef548ad23e29b18a88da..50ff6c2efd82b9ea1e6943c5e42701f821d98c9d 100644 (file)
 #include <asm/hvm/support.h>
 #include <mach_apic.h>
 
-int hard_smp_processor_id(void)
-{
-    return get_apic_id();
-}
-
 /*
  * send_IPI_mask(cpumask, vector): sends @vector IPI to CPUs in @cpumask,
  * excluding the local CPU. @cpumask may be empty.
index 833a0a52e34ff19c75310cab04749d2d5c27fba4..5d48bac1cad33c647e22bb4865e68b7dfb518405 100644 (file)
@@ -854,7 +854,7 @@ void __init smp_prepare_cpus(unsigned int max_cpus)
     {
         printk("weird, boot CPU (#%d) not listed by the BIOS.\n",
                boot_cpu_physical_apicid);
-        physid_set(hard_smp_processor_id(), phys_cpu_present_map);
+        physid_set(get_apic_id(), phys_cpu_present_map);
     }
 
     /* If we couldn't find a local APIC, then get out of here now! */
index fb0f42a6a71e23fc88b6ebd509f4657d5a82ee67..64f510b6ba2ee06b71c5bdfa8a6c946e3ced479a 100644 (file)
@@ -54,8 +54,6 @@ int cpu_add(uint32_t apic_id, uint32_t acpi_id, uint32_t pxm);
  */
 #define raw_smp_processor_id() (get_processor_id())
 
-int hard_smp_processor_id(void);
-
 void __stop_this_cpu(void);
 
 long cpu_up_helper(void *data);