Skip to content

Commit 8219efd

Browse files
Robin GongJassiBrar
authored andcommitted
mailbox: imx: fix crash in resume on i.mx8ulp
check 'priv->clk' before 'imx_mu_read()' otherwise crash happens on i.mx8ulp, since clock not enabled. Fixes: 4f0b776 ("mailbox: imx-mailbox: support i.MX8ULP MU") Reviewed-by: Jacky Bai <ping.bai@nxp.com> Signed-off-by: Robin Gong <yibin.gong@nxp.com> Signed-off-by: Peng Fan <peng.fan@nxp.com> Signed-off-by: Jassi Brar <jaswinder.singh@linaro.org>
1 parent 892cb52 commit 8219efd

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/mailbox/imx-mailbox.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -725,7 +725,7 @@ static int __maybe_unused imx_mu_resume_noirq(struct device *dev)
725725
* send failed, may lead to system freeze. This issue
726726
* is observed by testing freeze mode suspend.
727727
*/
728-
if (!imx_mu_read(priv, priv->dcfg->xCR[0]) && !priv->clk) {
728+
if (!priv->clk && !imx_mu_read(priv, priv->dcfg->xCR[0])) {
729729
for (i = 0; i < IMX_MU_xCR_MAX; i++)
730730
imx_mu_write(priv, priv->xcr[i], priv->dcfg->xCR[i]);
731731
}

0 commit comments

Comments
 (0)