]> git.baikalelectronics.ru Git - kernel.git/commit
[media] exynos4-is: Ensure fimc-is clocks are not enabled until properly configured
authorSylwester Nawrocki <s.nawrocki@samsung.com>
Fri, 31 May 2013 11:40:36 +0000 (08:40 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Sat, 8 Jun 2013 22:53:16 +0000 (19:53 -0300)
commitdcb5cb7edab54873c31877cb443b0fc3b2acebcc
tree8ac568ea27b7786ddd68bf408fb2ed6e7b1d6aa2
parent7a9673257a929cc06a92b222c091b9090135c1b7
[media] exynos4-is: Ensure fimc-is clocks are not enabled until properly configured

Use clk_prepare_enable/clk_unprepare_disable instead of preparing the
clocks during the driver initalization and then using just clk_disable/
clk_enable. The clock framework doesn't guarantee a clock will not get
enabled during e.g. clk_set_parent if clk_prepare has been called on it.
So we ensure clk_prepare() is called only when it is safe to enable
the clocks, i.e. the parent clocks and the clocks' frequencies are set.
It must be ensured the FIMC-IS clocks have proper frequencies before they
are enabled, otherwise the whole system will hang.

Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Kyunmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/platform/exynos4-is/fimc-is.c