arm/ast2600: Fix SMP booting with -kernel
Joel Stanley
maintainerPATCH 1/1 arm/ast2600: Fix SMP booting with -kernel
The ast2600 machines do not have PSCI firmware, so this property should have never been set. Removing this node fixes SMP booting Linux kernels that have PSCI enabled, as Linux fails to find PSCI in the device tree and falls back to the soc-specific method for enabling secondary CPUs.
The comment is out of date as Qemu has supported -kernel booting since 9bb6d14081ce ("aspeed: Add boot stub for smp booting"), in v5.1.
--- hw/arm/aspeed_ast2600.c | 7 ------- 1 file changed, 7 deletions(-)
hw/arm/aspeed_ast2600.c +0 -7
@@ -241,8 +241,6 @@ static void aspeed_soc_ast2600_realize(DeviceState *dev, Error **errp)/* CPU */ for (i =0 ; i < sc->num_cpus; i++) { -object_property_set_int (OBJECT (&s->cpu[i]),"psci-conduit" , -QEMU_PSCI_CONDUIT_SMC , &error_abort);if (sc->num_cpus >1 ) {object_property_set_int (OBJECT (&s->cpu[i]),"reset-cbar" ,ASPEED_A7MPCORE_ADDR , &error_abort);
@@ -253,11 +251,6 @@ static void aspeed_soc_ast2600_realize(DeviceState *dev, Error **errp)object_property_set_int (OBJECT (&s->cpu[i]),"cntfrq" ,1125000000 , &error_abort); -/* -* TODO: the secondary CPUs are started and a boot helper -* is needed when using -kernel -*/ -if (!qdev_realize (DEVICE (&s->cpu[i]),NULL , errp)) {return ; }
Signature · 1 line
2.30.1
Quoted 10 lines · Joel Stanley
The ast2600 machines do not have PSCI firmware, so this property should have never been set. Removing this node fixes SMP booting Linux kernels that have PSCI enabled, as Linux fails to find PSCI in the device tree and falls back to the soc-specific method for enabling secondary CPUs.
The comment is out of date as Qemu has supported -kernel booting since
9bb6d14081ce("aspeed: Add boot stub for smp booting"), in v5.1.Fixes f25c0ae1079d ("aspeed/soc: Add AST2600 support")Signed-off-by Joel Stanley <[email protected]>
Thanks
C.
Quoted 30 lines
--- hw/arm/aspeed_ast2600.c | 7 ------- 1 file changed, 7 deletions(-)hw/arm/aspeed_ast2600.c +0
-7@@ -241,8 +241,6 @@ static void aspeed_soc_ast2600_realize(DeviceState *dev, Error **errp)/* CPU */ for (i =0 ; i < sc->num_cpus; i++) { -object_property_set_int (OBJECT (&s->cpu[i]),"psci-conduit" , -QEMU_PSCI_CONDUIT_SMC , &error_abort);if (sc->num_cpus >1 ) {object_property_set_int (OBJECT (&s->cpu[i]),"reset-cbar" ,ASPEED_A7MPCORE_ADDR , &error_abort);@@ -253,11 +251,6 @@ static void aspeed_soc_ast2600_realize(DeviceState *dev, Error **errp)object_property_set_int (OBJECT (&s->cpu[i]),"cntfrq" ,1125000000 , &error_abort); -/* -* TODO: the secondary CPUs are started and a boot helper -* is needed when using -kernel -*/ -if (!qdev_realize (DEVICE (&s->cpu[i]),NULL , errp)) {return ; }