提交 11963a63 编写于 作者: V Vikas Sajjan 提交者: Inki Dae

drm/exynos: enable FIMD clocks

Common Clock Framework introduced the need to prepare clocks before
enabling them, otherwise clk_enable() fails. This patch adds clk_prepare_enable
and clk_disable_unprepare() calls to the driver.
This patch also removes clk_disable() from fimd_remove() as it will be done
by pm_runtime_put_sync.
Signed-off-by: NVikas Sajjan <vikas.sajjan@linaro.org>
Signed-off-by: NInki Dae <inki.dae@samsung.com>
上级 baa88c83
...@@ -801,18 +801,18 @@ static int fimd_clock(struct fimd_context *ctx, bool enable) ...@@ -801,18 +801,18 @@ static int fimd_clock(struct fimd_context *ctx, bool enable)
if (enable) { if (enable) {
int ret; int ret;
ret = clk_enable(ctx->bus_clk); ret = clk_prepare_enable(ctx->bus_clk);
if (ret < 0) if (ret < 0)
return ret; return ret;
ret = clk_enable(ctx->lcd_clk); ret = clk_prepare_enable(ctx->lcd_clk);
if (ret < 0) { if (ret < 0) {
clk_disable(ctx->bus_clk); clk_disable_unprepare(ctx->bus_clk);
return ret; return ret;
} }
} else { } else {
clk_disable(ctx->lcd_clk); clk_disable_unprepare(ctx->lcd_clk);
clk_disable(ctx->bus_clk); clk_disable_unprepare(ctx->bus_clk);
} }
return 0; return 0;
...@@ -996,9 +996,6 @@ static int fimd_remove(struct platform_device *pdev) ...@@ -996,9 +996,6 @@ static int fimd_remove(struct platform_device *pdev)
if (ctx->suspended) if (ctx->suspended)
goto out; goto out;
clk_disable(ctx->lcd_clk);
clk_disable(ctx->bus_clk);
pm_runtime_set_suspended(dev); pm_runtime_set_suspended(dev);
pm_runtime_put_sync(dev); pm_runtime_put_sync(dev);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册