diff mbox

[v2,6/6] arm/highbank: enable PSCI emulation support

Message ID 1400812209-26743-7-git-send-email-robherring2@gmail.com
State New
Headers show

Commit Message

Rob Herring May 23, 2014, 2:30 a.m. UTC
From: Rob Herring <rob.herring@linaro.org>

Enable PSCI emulation on highbank and midway platforms.

Note that this requires fixing the PSCI function IDs in the DTB to match
what QEMU is using. This should get fixed.

Signed-off-by: Rob Herring <rob.herring@linaro.org>
---
v2:
- Add error_abort on setting of start-powered-off.


 hw/arm/highbank.c | 9 +++++++++
 1 file changed, 9 insertions(+)

--
1.9.1

Comments

Peter Maydell June 3, 2014, 2:42 p.m. UTC | #1
On 23 May 2014 03:30, Rob Herring <robherring2@gmail.com> wrote:
> From: Rob Herring <rob.herring@linaro.org>
>
> Enable PSCI emulation on highbank and midway platforms.
>
> Note that this requires fixing the PSCI function IDs in the DTB to match
> what QEMU is using. This should get fixed.
>
> Signed-off-by: Rob Herring <rob.herring@linaro.org>

Reviewed-by: Peter Maydell <peter.maydell@linaro.org>

-- PMM
diff mbox

Patch

diff --git a/hw/arm/highbank.c b/hw/arm/highbank.c
index 24231e5..0cbc865 100644
--- a/hw/arm/highbank.c
+++ b/hw/arm/highbank.c
@@ -241,6 +241,15 @@  static void calxeda_init(QEMUMachineInitArgs *args, enum cxmachines machine)
         cpuobj = object_new(object_class_get_name(oc));
         cpu = ARM_CPU(cpuobj);

+        object_property_set_int(cpuobj, QEMU_PSCI_METHOD_SMC, "psci-method",
+                                &error_abort);
+
+        /* Secondary CPUs start in PSCI powered-down state */
+        if (n > 0) {
+            object_property_set_bool(cpuobj, true, "start-powered-off",
+                                     &error_abort);
+        }
+
         if (object_property_find(cpuobj, "reset-cbar", NULL)) {
             object_property_set_int(cpuobj, MPCORE_PERIPHBASE,
                                     "reset-cbar", &error_abort);