aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/exynos
diff options
context:
space:
mode:
authorVikas Sajjan <vikas.sajjan@linaro.org>2013-04-08 07:07:45 -0400
committerInki Dae <daeinki@gmail.com>2013-04-20 11:04:25 -0400
commitb4e3a3e844a0e33cf106a1c9f27ff93340c37640 (patch)
treea0631bfee37ee9dcc6f787bacd685a8e020416f9 /drivers/gpu/drm/exynos
parentdd4d34fde068a9362d09292d881ce4743bb11c7f (diff)
drm/exynos: prepare FIMD clocks
While migrating to common clock framework (CCF), I found that the FIMD clocks were pulled down by the CCF. If CCF finds any clock(s) which has NOT been claimed by any of the drivers, then such clock(s) are PULLed low by CCF. Calling clk_prepare() for FIMD clocks fixes the issue. This patch also replaces clk_disable() with clk_unprepare() during exit, since clk_prepare() is called in fimd_probe(). Signed-off-by: Vikas Sajjan <vikas.sajjan@linaro.org> Signed-off-by: Inki Dae <inki.dae@samsung.com>
Diffstat (limited to 'drivers/gpu/drm/exynos')
-rw-r--r--drivers/gpu/drm/exynos/exynos_drm_fimd.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimd.c b/drivers/gpu/drm/exynos/exynos_drm_fimd.c
index 4073430e22c3..15e58f5abe02 100644
--- a/drivers/gpu/drm/exynos/exynos_drm_fimd.c
+++ b/drivers/gpu/drm/exynos/exynos_drm_fimd.c
@@ -949,6 +949,16 @@ static int fimd_probe(struct platform_device *pdev)
949 return ret; 949 return ret;
950 } 950 }
951 951
952 ret = clk_prepare(ctx->bus_clk);
953 if (ret < 0)
954 return ret;
955
956 ret = clk_prepare(ctx->lcd_clk);
957 if (ret < 0) {
958 clk_unprepare(ctx->bus_clk);
959 return ret;
960 }
961
952 ctx->vidcon0 = pdata->vidcon0; 962 ctx->vidcon0 = pdata->vidcon0;
953 ctx->vidcon1 = pdata->vidcon1; 963 ctx->vidcon1 = pdata->vidcon1;
954 ctx->default_win = pdata->default_win; 964 ctx->default_win = pdata->default_win;
@@ -996,8 +1006,8 @@ static int fimd_remove(struct platform_device *pdev)
996 if (ctx->suspended) 1006 if (ctx->suspended)
997 goto out; 1007 goto out;
998 1008
999 clk_disable(ctx->lcd_clk); 1009 clk_unprepare(ctx->lcd_clk);
1000 clk_disable(ctx->bus_clk); 1010 clk_unprepare(ctx->bus_clk);
1001 1011
1002 pm_runtime_set_suspended(dev); 1012 pm_runtime_set_suspended(dev);
1003 pm_runtime_put_sync(dev); 1013 pm_runtime_put_sync(dev);