Commit 1d9ffbc6 authored by Geert Uytterhoeven's avatar Geert Uytterhoeven

soc: renesas: rmobile-sysc: Mark fwnode when PM domain is added

Currently, there are two drivers binding to the R-Mobile System
Controller (SYSC):
  - The rmobile-sysc driver registers PM domains from a core_initcall(),
    and does not use a platform driver,
  - The optional rmobile-reset driver registers a reset handler, and
    does use a platform driver.

As fw_devlink only considers devices, commit bab2d712 ("PM:
domains: Mark fwnodes when their powerdomain is added/removed") works
only for PM Domain drivers where the DT node is a real device node, and
not for PM Domain drivers using a hierarchical representation inside a
subnode.  Hence if fw_devlink is enabled, probing of on-chip devices
that are part of the SYSC PM domain is deferred until the optional
rmobile-reset driver has been bound.   If the rmobile-reset driver is
not available, this will never happen, and thus lead to complete system
boot failures.

Fix this by explicitly marking the fwnode initialized.
Suggested-by: default avatarSaravana Kannan <saravanak@google.com>
Signed-off-by: default avatarGeert Uytterhoeven <geert+renesas@glider.be>
Acked-by: default avatarSaravana Kannan <saravanak@google.com>
Link: https://lore.kernel.org/r/20210216123958.3180014-1-geert+renesas@glider.be
parent 2fb72440
...@@ -342,6 +342,8 @@ static int __init rmobile_init_pm_domains(void) ...@@ -342,6 +342,8 @@ static int __init rmobile_init_pm_domains(void)
of_node_put(np); of_node_put(np);
break; break;
} }
fwnode_dev_initialized(&np->fwnode, true);
} }
put_special_pds(); put_special_pds();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment