aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/platform/mtk-vpu
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/media/platform/mtk-vpu')
-rw-r--r--drivers/media/platform/mtk-vpu/mtk_vpu.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/media/platform/mtk-vpu/mtk_vpu.c b/drivers/media/platform/mtk-vpu/mtk_vpu.c
index c8a56271b259..7c4428cf14e6 100644
--- a/drivers/media/platform/mtk-vpu/mtk_vpu.c
+++ b/drivers/media/platform/mtk-vpu/mtk_vpu.c
@@ -987,6 +987,12 @@ static int mtk_vpu_suspend(struct device *dev)
return ret;
}
+ if (!vpu_running(vpu)) {
+ vpu_clock_disable(vpu);
+ clk_unprepare(vpu->clk);
+ return 0;
+ }
+
mutex_lock(&vpu->vpu_mutex);
/* disable vpu timer interrupt */
vpu_cfg_writel(vpu, vpu_cfg_readl(vpu, VPU_INT_STATUS) | VPU_IDLE_STATE,

Privacy Policy