arm: always start from first_cpu when registering loader cpu reset callback
commit75ed2c02484101d5b4995c56e78a894ac244ce05
authorIgor Mammedov <imammedo@redhat.com>
Thu, 26 Apr 2018 10:04:38 +0000 (26 11:04 +0100)
committerPeter Maydell <peter.maydell@linaro.org>
Thu, 26 Apr 2018 10:04:38 +0000 (26 11:04 +0100)
tree251b18cfe6fe559e49bb699ff869445507143990
parent14ec3cbd7c1e31dca4d23f028100c8f43e156573
arm: always start from first_cpu when registering loader cpu reset callback

if arm_load_kernel() were passed non first_cpu, QEMU would end up
with partially set do_cpu_reset() callback leaving some CPUs without it.

Make sure that do_cpu_reset() is registered for all CPUs by enumerating
CPUs from first_cpu.

(In practice every board that we have was passing us the first CPU
as the boot CPU, either directly or indirectly, so this wasn't
causing incorrect behaviour.)

Signed-off-by: Igor Mammedov <imammedo@redhat.com>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
[PMM: added a note that this isn't a behaviour change]
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
hw/arm/boot.c