diff options
-rw-r--r-- | plat/imx/imx8m/imx8m_psci_common.c | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/plat/imx/imx8m/imx8m_psci_common.c b/plat/imx/imx8m/imx8m_psci_common.c index 452958ce..ca0a5fc3 100644 --- a/plat/imx/imx8m/imx8m_psci_common.c +++ b/plat/imx/imx8m/imx8m_psci_common.c @@ -126,8 +126,13 @@ void imx_domain_suspend(const psci_power_state_t *target_state) dram_enter_retention(); imx_anamix_override(true); imx_noc_wrapper_pre_suspend(core_id); + } else { + /* flag 0xD means DSP LPA buffer is in OCRAM */ + if (mmio_read_32(IMX_SRC_BASE + LPA_STATUS) == 0xD) + dram_enter_retention(); } - imx_set_sys_wakeup(core_id, true); + + imx_set_sys_wakeup(core_id, true); } } @@ -142,8 +147,13 @@ void imx_domain_suspend_finish(const psci_power_state_t *target_state) imx_anamix_override(false); dram_exit_retention(); imx_set_sys_lpm(core_id, false); + } else { + /* flag 0xD means DSP LPA buffer is in OCRAM */ + if (mmio_read_32(IMX_SRC_BASE + LPA_STATUS) == 0xD) + dram_exit_retention(); } - imx_set_sys_wakeup(core_id, false); + + imx_set_sys_wakeup(core_id, false); } if (!is_local_state_run(CLUSTER_PWR_STATE(target_state))) { |