Not having apics, Voyager can't use the default apic implementation of
these, it has to read from a special port in the VIC to get the
processor ID, so abstract these functions in smp_ops to allow voyager
to live simultaneously with the apic code.
diff --git a/arch/x86/xen/smp.c b/arch/x86/xen/smp.c
index 035582a..0dfb8c0 100644
--- a/arch/x86/xen/smp.c
+++ b/arch/x86/xen/smp.c
@@ -450,6 +450,11 @@ static irqreturn_t xen_call_function_single_interrupt(int irq, void *dev_id)
return IRQ_HANDLED;
}
+static int xen_hard_smp_processor_id(void)
+{
+ return read_apic_id();
+}
+
static const struct smp_ops xen_smp_ops __initdata = {
.smp_prepare_boot_cpu = xen_smp_prepare_boot_cpu,
.smp_prepare_cpus = xen_smp_prepare_cpus,
@@ -465,6 +470,8 @@ static const struct smp_ops xen_smp_ops __initdata = {
.send_call_func_ipi = xen_smp_send_call_function_ipi,
.send_call_func_single_ipi = xen_smp_send_call_function_single_ipi,
+ .hard_smp_processor_id = xen_hard_smp_processor_id,
+ .safe_smp_processor_id = apic_safe_smp_processor_id,