PCI: imx6: Enable i.MX6QP PCIe power management support

i.MX6QP PCIe supports the reset logic, thus it can reset itself to the
initialized state when exit from L2 or L3 states.

Enable the i.MX6QP PCIe suspend/resume operations support.

Link: https://lore.kernel.org/r/1645425237-4071-2-git-send-email-hongxing.zhu@nxp.com
Signed-off-by: Richard Zhu <hongxing.zhu@nxp.com>
Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Reviewed-by: Lucas Stach <l.stach@pengutronix.de>
This commit is contained in:
Richard Zhu 2022-02-21 14:33:57 +08:00 committed by Lorenzo Pieralisi
parent f81f095e87
commit f81dd043ec

View File

@ -917,6 +917,7 @@ static void imx6_pcie_pm_turnoff(struct imx6_pcie *imx6_pcie)
/* Others poke directly at IOMUXC registers */ /* Others poke directly at IOMUXC registers */
switch (imx6_pcie->drvdata->variant) { switch (imx6_pcie->drvdata->variant) {
case IMX6SX: case IMX6SX:
case IMX6QP:
regmap_update_bits(imx6_pcie->iomuxc_gpr, IOMUXC_GPR12, regmap_update_bits(imx6_pcie->iomuxc_gpr, IOMUXC_GPR12,
IMX6SX_GPR12_PCIE_PM_TURN_OFF, IMX6SX_GPR12_PCIE_PM_TURN_OFF,
IMX6SX_GPR12_PCIE_PM_TURN_OFF); IMX6SX_GPR12_PCIE_PM_TURN_OFF);
@ -1246,7 +1247,8 @@ static const struct imx6_pcie_drvdata drvdata[] = {
[IMX6QP] = { [IMX6QP] = {
.variant = IMX6QP, .variant = IMX6QP,
.flags = IMX6_PCIE_FLAG_IMX6_PHY | .flags = IMX6_PCIE_FLAG_IMX6_PHY |
IMX6_PCIE_FLAG_IMX6_SPEED_CHANGE, IMX6_PCIE_FLAG_IMX6_SPEED_CHANGE |
IMX6_PCIE_FLAG_SUPPORTS_SUSPEND,
.dbi_length = 0x200, .dbi_length = 0x200,
}, },
[IMX7D] = { [IMX7D] = {