xen/arm: setup: Check errata for boot CPU later on
authorJulien Grall <julien.grall@arm.com>
Tue, 12 Jun 2018 11:36:33 +0000 (12:36 +0100)
committerJulien Grall <julien.grall@arm.com>
Fri, 22 Jun 2018 01:55:12 +0000 (02:55 +0100)
Some errata will rely on the SMCCC version which is detected by
psci_init().

This is part of XSA-263.

Signed-off-by: Julien Grall <julien.grall@arm.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
xen/arch/arm/setup.c

index 1d6f6bf37efa833c06c4963494e54168eb4b52c2..ac93de478699d47493eef76edf092133c5fe4185 100644 (file)
@@ -171,8 +171,6 @@ static void __init processor_id(void)
     }
 
     processor_setup();
-
-    check_local_cpu_errata();
 }
 
 void dt_unreserved_regions(paddr_t s, paddr_t e,
@@ -779,6 +777,12 @@ void __init start_xen(unsigned long boot_phys_offset,
     printk(XENLOG_INFO "SMP: Allowing %u CPUs\n", cpus);
     nr_cpu_ids = cpus;
 
+    /*
+     * Some errata relies on SMCCC version which is detected by psci_init()
+     * (called from smp_init_cpus()).
+     */
+    check_local_cpu_errata();
+
     init_xen_time();
 
     gic_init();