[PATCH v10 13/27] drivers: firmware: psci: Support hierarchical CPU idle states
From: Ulf Hansson
Date: Thu Nov 29 2018 - 12:49:08 EST
From: Lina Iyer <lina.iyer@xxxxxxxxxx>
Currently CPU's idle states are represented in a flattened model, via the
"cpu-idle-states" binding from within the CPU's device nodes.
Support the hierarchical layout, simply by converting to calling the new OF
helper, of_get_cpu_state_node().
Cc: Lina Iyer <ilina@xxxxxxxxxxxxxx>
Suggested-by: Sudeep Holla <sudeep.holla@xxxxxxx>
Signed-off-by: Lina Iyer <lina.iyer@xxxxxxxxxx>
Co-developed-by: Ulf Hansson <ulf.hansson@xxxxxxxxxx>
Signed-off-by: Ulf Hansson <ulf.hansson@xxxxxxxxxx>
---
Changes in v10:
- None.
---
drivers/firmware/psci/psci.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/firmware/psci/psci.c b/drivers/firmware/psci/psci.c
index cbfc936d251c..631e20720a22 100644
--- a/drivers/firmware/psci/psci.c
+++ b/drivers/firmware/psci/psci.c
@@ -300,7 +300,7 @@ static int psci_dt_cpu_init_idle(struct cpuidle_driver *drv,
return -ENOMEM;
for (i = 0; i < num_state_nodes; i++) {
- state_node = of_parse_phandle(cpu_node, "cpu-idle-states", i);
+ state_node = of_get_cpu_state_node(cpu_node, i);
if (!state_node)
break;
--
2.17.1