Revert "soc: imx: gpcv2: move reset assert after requesting domain power up"
authorLucas Stach <l.stach@pengutronix.de>
Sat, 2 Oct 2021 00:59:37 +0000 (02:59 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 6 Nov 2021 13:13:30 +0000 (14:13 +0100)
commit 2b2f106eb55276a60a89ac27a52d0d738b57a546 upstream.

This reverts commit a77ebdd9f553. It turns out that the VPU domain has no
different requirements, even though the downstream ATF implementation seems
to suggest otherwise. Powering on the domain with the reset asserted works
fine. As the changed sequence has caused sporadic issues with the GPU
domains, just revert the change to go back to the working sequence.

Cc: <stable@vger.kernel.org> # 5.14
Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Acked-by: Peng Fan <peng.fan@nxp.com>
Tested-by: Adam Ford <aford173@gmail.com> #imx8mm-beacon
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/soc/imx/gpcv2.c

index 34a9ac1..8b7a017 100644 (file)
@@ -244,6 +244,8 @@ static int imx_pgc_power_up(struct generic_pm_domain *genpd)
                goto out_regulator_disable;
        }
 
+       reset_control_assert(domain->reset);
+
        if (domain->bits.pxx) {
                /* request the domain to power up */
                regmap_update_bits(domain->regmap, GPC_PU_PGC_SW_PUP_REQ,
@@ -266,8 +268,6 @@ static int imx_pgc_power_up(struct generic_pm_domain *genpd)
                                  GPC_PGC_CTRL_PCR);
        }
 
-       reset_control_assert(domain->reset);
-
        /* delay for reset to propagate */
        udelay(5);