soc: xilinx: move PM_INIT_FINALIZE to zynqmp_pm_domains driver
authorMichael Tretter <m.tretter@pengutronix.de>
Wed, 25 Aug 2021 15:03:10 +0000 (17:03 +0200)
committerMichal Simek <michal.simek@xilinx.com>
Wed, 8 Dec 2021 11:53:35 +0000 (12:53 +0100)
commit7fd890b89dea55eb5866640eb8befad26d558161
treefcd58becb04f4eb724861d4ab4159a2f06b40772
parentfa55b7dcdc43c1aa1ba12bca9d2dd4318c2a0dbf
soc: xilinx: move PM_INIT_FINALIZE to zynqmp_pm_domains driver

PM_INIT_FINALIZE tells the PMU FW that Linux is able to handle the power
management nodes that are provided by the PMU FW. Nodes that are not
requested are shut down after this call.

Calling PM_INIT_FINALIZE from the zynqmp_power driver is wrong. The PM
node request mechanism is implemented in the zynqmp_pm_domains driver,
which must also call PM_INIT_FINALIZE.

Due to the behavior of the PMU FW, all devices must be powered up before
PM_INIT_FINALIZE is called, because otherwise the devices might
misbehave. Calling PM_INIT_FINALIZE from the sync_state device callback
ensures that all users probed successfully before the PMU FW is allowed
to power off unused domains.

Signed-off-by: Michael Tretter <m.tretter@pengutronix.de>
Acked-by: Michal Simek <michal.simek@xilinx.com>
Acked-by: Rajan Vaja <rajan.vaja@xilinx.com>
Link: https://lore.kernel.org/r/20210825150313.4033156-2-m.tretter@pengutronix.de
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
drivers/soc/xilinx/zynqmp_pm_domains.c
drivers/soc/xilinx/zynqmp_power.c