diff options
author | Robin Gong <yibin.gong@nxp.com> | 2018-04-13 19:35:12 +0800 |
---|---|---|
committer | Jason Liu <jason.hui.liu@nxp.com> | 2019-02-12 10:31:14 +0800 |
commit | 7582e8b9c8c79dbd544cd53b3664196a0eef2c03 (patch) | |
tree | cda1b5c21488fb3d5dd05b6070b45aca1e006298 /arch/arm/mach-imx | |
parent | e974df560173721413803da93921284794c1b354 (diff) |
MLK-18004: ARM: imx: pm-imx7ulp: fix resume failure in freeze mode
This patch fix resume failure in freeze suspend mode on i.mx7ULP
("echo freeze > /sys/power/state") while pressing onoff key or
enabling rtc alarm wakeup. In freeze mode, kernel can only be woken
up by drivers which register wakup source such as 'device_init_wakeup'
or 'irq_set_irq_wake', otherwise, kernel will wait for irq handler
freeze_wake(). Unfortunately, our NMI interrupt which used to wakeup
A7 by M4 is not a common device and request irq as 'IRQF_NO_SUSPEND'
which means feeze_wake() never get chance to run while wakeup by any
event from M4 such as RTC, ONOFF. In this case, use pm_system_wakeup()
instead in NMI interrupt handle to trigger freeze_wake() directly.
Signed-off-by: Robin Gong <yibin.gong@nxp.com>
Reviewed-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit e069300629d4cba26a2812c85f37ccaf0bd2e683)
Diffstat (limited to 'arch/arm/mach-imx')
-rw-r--r-- | arch/arm/mach-imx/pm-imx7ulp.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/arch/arm/mach-imx/pm-imx7ulp.c b/arch/arm/mach-imx/pm-imx7ulp.c index 63fe0d4ed7f5..b4789a305742 100644 --- a/arch/arm/mach-imx/pm-imx7ulp.c +++ b/arch/arm/mach-imx/pm-imx7ulp.c @@ -788,6 +788,7 @@ static irqreturn_t imx7ulp_nmi_isr(int irq, void *param) { writel_relaxed(readl_relaxed(mu_base + MU_SR) | MU_B_SR_NMIC, mu_base + MU_SR); + pm_system_wakeup(); return IRQ_HANDLED; } |