[media] exynos4-is: Fix compilation for !CONFIG_COMMON_CLK
authorSylwester Nawrocki <s.nawrocki@samsung.com>
Tue, 15 Apr 2014 17:34:29 +0000 (14:34 -0300)
committerMauro Carvalho Chehab <m.chehab@samsung.com>
Fri, 23 May 2014 18:49:39 +0000 (15:49 -0300)
CONFIG_COMMON_CLK is not enabled on S5PV210 platform, so include
some clk API data structures conditionally to avoid compilation
errors. These #ifdefs will be removed for next kernel release,
when the S5PV210 platform moves to DT and the common clk API.

Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Acked-by: Kyungmin Park <kyungmin.park@samsung.com>
Cc: stable@vger.kernel.org # for 3.15
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
drivers/media/platform/exynos4-is/media-dev.c
drivers/media/platform/exynos4-is/media-dev.h

index e62211a..6e2d604 100644 (file)
@@ -1520,7 +1520,7 @@ err:
 }
 #else
 #define fimc_md_register_clk_provider(fmd) (0)
-#define fimc_md_unregister_clk_provider(fmd) (0)
+#define fimc_md_unregister_clk_provider(fmd)
 #endif
 
 static int subdev_notifier_bound(struct v4l2_async_notifier *notifier,
index ee1e251..58c4945 100644 (file)
@@ -94,7 +94,9 @@ struct fimc_sensor_info {
 };
 
 struct cam_clk {
+#ifdef CONFIG_COMMON_CLK
        struct clk_hw hw;
+#endif
        struct fimc_md *fmd;
 };
 #define to_cam_clk(_hw) container_of(_hw, struct cam_clk, hw)
@@ -142,7 +144,9 @@ struct fimc_md {
 
        struct cam_clk_provider {
                struct clk *clks[FIMC_MAX_CAMCLKS];
+#ifdef CONFIG_COMMON_CLK
                struct clk_onecell_data clk_data;
+#endif
                struct device_node *of_node;
                struct cam_clk camclk[FIMC_MAX_CAMCLKS];
                int num_clocks;