[media] s5p-csis: Fix clock handling on error path in probe()
authorSylwester Nawrocki <s.nawrocki@samsung.com>
Fri, 18 Jan 2013 16:52:38 +0000 (13:52 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Wed, 6 Feb 2013 11:41:17 +0000 (09:41 -0200)
commit8cd5d42ac6d75143ab4bf44a15f76245a7f6c884
treefaf5be99ab17302ded0757a75bfa40c84ee1e3f0
parent05c79d0d1d0d44c2195d63d1e7c62e358eadeadf
[media] s5p-csis: Fix clock handling on error path in probe()

Move e_clkput label after the clk_disable() call so a not acquired clock
is not attempted to be disabled. This fixes runtime warnings like:
 s5p-mipi-csis 11880000.csis: failed to get clock: sclk_csis
 ------------[ cut here ]------------
 WARNING: at drivers/clk/clk.c:478 clk_disable+0x24/0x34()
 Modules linked in:
 [<c001603c>] (unwind_backtrace+0x0/0x13c) from [<c0022060>] (warn_slowpath_common+0x54/0x64)
 [<c0022060>] (warn_slowpath_common+0x54/0x64) from [<c002208c>] (warn_slowpath_null+0x1c/0x24)
 [<c002208c>] (warn_slowpath_null+0x1c/0x24) from [<c033f868>] (clk_disable+0x24/0x34)
 [<c033f868>] (clk_disable+0x24/0x34) from [<c02feff8>] (s5pcsis_probe+0x25c/0x4c8)
 [<c02feff8>] (s5pcsis_probe+0x25c/0x4c8) from [<c0268e34>] (platform_drv_probe+0x18/0x1c)
 [<c0268e34>] (platform_drv_probe+0x18/0x1c) from [<c0267700>] (driver_probe_device+0xa4/0x368)
 [<c0267700>] (driver_probe_device+0xa4/0x368) from [<c0267a50>] (__driver_attach+0x8c/0x90)
 [<c0267a50>] (__driver_attach+0x8c/0x90) from [<c0265c94>] (bus_for_each_dev+0x60/0x8c)
 [<c0265c94>] (bus_for_each_dev+0x60/0x8c) from [<c02665e8>] (bus_add_driver+0x20c/0x2d4)
 [<c02665e8>] (bus_add_driver+0x20c/0x2d4) from [<c0268064>] (driver_register+0x78/0x194)
 [<c0268064>] (driver_register+0x78/0x194) from [<c0008668>] (do_one_initcall+0x34/0x188)
 [<c0008668>] (do_one_initcall+0x34/0x188) from [<c03de57c>] (kernel_init+0x180/0x2f0)
 [<c03de57c>] (kernel_init+0x180/0x2f0) from [<c000f0d8>] (ret_from_fork+0x14/0x3c)
 ---[ end trace 0c5a55345c42530b ]---

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