Boot CPUs sequentially
Currently the boot-wrapper initializes all CPUs in parallel. This means
that we cannot log errors as they happen, as this would mean multiple
CPUs concurrently writing to the UART, producing garbled output. To
produce meaningful output we have to special-case errors on the boot CPU
and hope CPUs have been configured consistently.
To make it easier to handle errors, boot CPUs sequentially so that errors
can be logged as they happen. With this change it's pretty clear that
the cpu_init_bootmethod() abstraction isn't helpful, and so this is
removed with cpu_init_arch() directly initializing PSCI where necessary.
When things go well this looks like:
| Boot-wrapper v0.2
| Entered at EL3
| Memory layout:
| [0000000080000000..0000000080001f90] => boot-wrapper
| [000000008000fff8..0000000080010000] => mbox
| [0000000080200000..0000000082cbaa00] => kernel
| [0000000088000000..0000000088002df1] => dtb
| CPU0: (MPIDR 0000000000000000) initializing...
| CPU1: (MPIDR 0000000000000100) initializing...
| CPU2: (MPIDR 0000000000000200) initializing...
| CPU3: (MPIDR 0000000000000300) initializing...
| CPU4: (MPIDR 0000000000010000) initializing...
| CPU5: (MPIDR 0000000000010100) initializing...
| CPU6: (MPIDR 0000000000010200) initializing...
| CPU7: (MPIDR 0000000000010300) initializing...
| All CPUs initialized. Entering kernel...
|
| [ 0.000000] Booting Linux on physical CPU 0x0000000000 [0x410fd0f0]
Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Acked-by: Marc Zyngier <maz@kernel.org>
Reviewed-by: Andre Przywara <andre.przywara@arm.com>
Cc: Akos Denke <akos.denke@arm.com>
Cc: Luca Fancellu <luca.fancellu@arm.com>
8 files changed