From 288f1d55b58c4d18b50fd745fe4559c0db2a1a03 Mon Sep 17 00:00:00 2001 From: Sandor Yu Date: Mon, 19 Jan 2015 14:36:59 +0800 Subject: [PATCH] MLK-10115: ov5640:define function ov5640_turn_on_AE_AG() with static ov5640 driver will failed to build with build-in: drivers/media/platform/mxc/subdev/built-in.o: In function `ov5640_turn_on_AE_AG': ov5640.c:(.text+0x3890): multiple definition of `ov5640_turn_on_AE_AG' drivers/media/platform/mxc/capture/built-in.o:v4l2-int-device.c:(.text+0x783c): first defined here make[3]: *** [drivers/media/platform/built-in.o] Error 1 make[2]: *** [drivers/media/platform] Error 2 make[1]: *** [drivers/media] Error 2 make: *** [drivers] Error 2 make: *** Waiting for unfinished jobs.... It is caused by function of ov5640_turn_on_AE_AG define as global function, change it to static function to resolv the issue. Signed-off-by: Sandor Yu --- drivers/media/platform/mxc/capture/ov5640.c | 2 +- drivers/media/platform/mxc/subdev/ov5640.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/media/platform/mxc/capture/ov5640.c b/drivers/media/platform/mxc/capture/ov5640.c index d781684d1340..2f7253c3c186 100644 --- a/drivers/media/platform/mxc/capture/ov5640.c +++ b/drivers/media/platform/mxc/capture/ov5640.c @@ -991,7 +991,7 @@ static int ov5640_set_night_mode(int enable) /* enable = 0 to turn off AEC/AGC enable = 1 to turn on AEC/AGC */ -void ov5640_turn_on_AE_AG(int enable) +static void ov5640_turn_on_AE_AG(int enable) { u8 ae_ag_ctrl; diff --git a/drivers/media/platform/mxc/subdev/ov5640.c b/drivers/media/platform/mxc/subdev/ov5640.c index ee3870748e24..b4247e563a90 100644 --- a/drivers/media/platform/mxc/subdev/ov5640.c +++ b/drivers/media/platform/mxc/subdev/ov5640.c @@ -1076,7 +1076,7 @@ static int ov5640_set_night_mode(int enable) /* enable = 0 to turn off AEC/AGC enable = 1 to turn on AEC/AGC */ -void ov5640_turn_on_AE_AG(int enable) +static void ov5640_turn_on_AE_AG(int enable) { u8 ae_ag_ctrl; -- 2.39.5