summaryrefslogtreecommitdiff
path: root/drivers/media/platform/exynos-gsc
diff options
context:
space:
mode:
authorUlf Hansson <ulf.hansson@linaro.org>2016-11-09 17:23:55 +0300
committerMauro Carvalho Chehab <mchehab@s-opensource.com>2016-11-16 21:33:09 +0300
commit7ebcb3e842bd933fa6792414a3b369a661d99665 (patch)
tree18ca81a286711033448ba88c00abb88d54204a2d /drivers/media/platform/exynos-gsc
parenta006c04e6218bb82c11888d9b99ef642bd64cf93 (diff)
downloadlinux-7ebcb3e842bd933fa6792414a3b369a661d99665.tar.xz
[media] exynos-gsc: Do full clock gating at runtime PM suspend
To potentially save more power in runtime PM suspend state, let's also prepare/unprepare the clock from the runtime PM callbacks. [mszyprow: rebased onto v4.9-rc4] Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Tested-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Diffstat (limited to 'drivers/media/platform/exynos-gsc')
-rw-r--r--drivers/media/platform/exynos-gsc/gsc-core.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/media/platform/exynos-gsc/gsc-core.c b/drivers/media/platform/exynos-gsc/gsc-core.c
index e62765328848..3ac588f5c558 100644
--- a/drivers/media/platform/exynos-gsc/gsc-core.c
+++ b/drivers/media/platform/exynos-gsc/gsc-core.c
@@ -1154,7 +1154,7 @@ static int gsc_runtime_resume(struct device *dev)
pr_debug("gsc%d: state: 0x%lx", gsc->id, gsc->state);
- ret = clk_enable(gsc->clock);
+ ret = clk_prepare_enable(gsc->clock);
if (ret)
return ret;
@@ -1172,7 +1172,7 @@ static int gsc_runtime_suspend(struct device *dev)
ret = gsc_m2m_suspend(gsc);
if (!ret)
- clk_disable(gsc->clock);
+ clk_disable_unprepare(gsc->clock);
pr_debug("gsc%d: state: 0x%lx", gsc->id, gsc->state);
return ret;