On Thu, Feb 13, 2014 at 8:26 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > Newer versions of the Linux kernel (as of commit bc41b8724 in 3.12) > now assume that if the CPU is a Cortex-A9 and the reset value of the > PERIPHBASE/CBAR register is zero then the CPU is a specific buggy > single core A9 SoC, and will not try to start other cores. Since we > now have a CPU property for the reset value of the CBAR, we can > just fix the vexpress board model to correctly set CBAR so SMP > works again. To avoid duplicate boilerplate code in both the A9 > and A15 daughterboard init functions, we split out the CPU and > private memory region init to its own function. > > Signed-off-by: Peter Maydell <peter.mayd...@linaro.org> > Reported-by: Rob Herring <rob.herr...@linaro.org> > --- > Thanks to Rob for tracking down this SMP boot issue and identifying > the offending kernel change (which personally I think is a terrible > hack, but it's in shipping kernels and our models ought to be > accurate for CBAR anyway).
And i was working on the fix as well... > We should probably propagate this fix to all our A9-based models > before 2.0 release: I think the remaining ones to fix would be > realview-pbx-a9 and exynos4210. > > QOM syntax cribbed from the zynq board so I assume it is up to > current standards. > > hw/arm/vexpress.c | 116 > +++++++++++++++++++++++++----------------------------- > 1 file changed, 54 insertions(+), 62 deletions(-) > > diff --git a/hw/arm/vexpress.c b/hw/arm/vexpress.c > index ef1707a..e4ced8f 100644 > --- a/hw/arm/vexpress.c > +++ b/hw/arm/vexpress.c > @@ -32,6 +32,7 @@ > #include "sysemu/blockdev.h" > #include "hw/block/flash.h" > #include "sysemu/device_tree.h" > +#include "qemu/error-report.h" > #include <libfdt.h> > > #define VEXPRESS_BOARD_ID 0x8e0 > @@ -173,6 +174,57 @@ struct VEDBoardInfo { > DBoardInitFn *init; > }; > > +static void init_cpus(const char *cpu_model, const char *privdev, > + hwaddr periphbase, qemu_irq *pic) There is nothing really vexpress specific about this function other than number of irqs. This is really just expanding cpu_arm_init which is the route I was going down. Rob