diff options
Diffstat (limited to 'drivers/media/video/mt9v022.c')
-rw-r--r-- | drivers/media/video/mt9v022.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/media/video/mt9v022.c b/drivers/media/video/mt9v022.c index 5fbeaa305f35..468333946d57 100644 --- a/drivers/media/video/mt9v022.c +++ b/drivers/media/video/mt9v022.c | |||
@@ -18,7 +18,9 @@ | |||
18 | #include <media/v4l2-chip-ident.h> | 18 | #include <media/v4l2-chip-ident.h> |
19 | #include <media/soc_camera.h> | 19 | #include <media/soc_camera.h> |
20 | 20 | ||
21 | #ifdef CONFIG_MT9M001_PCA9536_SWITCH | ||
21 | #include <asm/gpio.h> | 22 | #include <asm/gpio.h> |
23 | #endif | ||
22 | 24 | ||
23 | /* mt9v022 i2c address 0x48, 0x4c, 0x58, 0x5c | 25 | /* mt9v022 i2c address 0x48, 0x4c, 0x58, 0x5c |
24 | * The platform has to define i2c_board_info | 26 | * The platform has to define i2c_board_info |
@@ -302,10 +304,6 @@ static int mt9v022_set_capture_format(struct soc_camera_device *icd, | |||
302 | if ((mt9v022->datawidth != 10 && (width_flag == IS_DATAWIDTH_10)) || | 304 | if ((mt9v022->datawidth != 10 && (width_flag == IS_DATAWIDTH_10)) || |
303 | (mt9v022->datawidth != 9 && (width_flag == IS_DATAWIDTH_9)) || | 305 | (mt9v022->datawidth != 9 && (width_flag == IS_DATAWIDTH_9)) || |
304 | (mt9v022->datawidth != 8 && (width_flag == IS_DATAWIDTH_8))) { | 306 | (mt9v022->datawidth != 8 && (width_flag == IS_DATAWIDTH_8))) { |
305 | /* data width switch requested */ | ||
306 | if (!gpio_is_valid(mt9v022->switch_gpio)) | ||
307 | return -EINVAL; | ||
308 | |||
309 | /* Well, we actually only can do 10 or 8 bits... */ | 307 | /* Well, we actually only can do 10 or 8 bits... */ |
310 | if (width_flag == IS_DATAWIDTH_9) | 308 | if (width_flag == IS_DATAWIDTH_9) |
311 | return -EINVAL; | 309 | return -EINVAL; |