aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorGuennadi Liakhovetski <g.liakhovetski@gmx.de>2011-07-28 13:42:24 -0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2011-11-03 16:27:59 -0400
commit6c67056a77b3087c40cd97a12930688014ef29c9 (patch)
tree56b909593352dbda83e028fba86beb0c30db3423 /drivers
parent0125b7c2fcc324bccd9c5e56b4afeecaac14c56d (diff)
[media] V4L: ov2640: remove superfluous soc-camera client operations
Now that all soc-camera hosts have been ported to use V4L2 subdevice mediabus-config operations and soc-camera client bus-parameter operations have been made optional, they can be removed. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/media/video/ov2640.c40
1 files changed, 0 insertions, 40 deletions
diff --git a/drivers/media/video/ov2640.c b/drivers/media/video/ov2640.c
index 31f361ed7cc5..2826aff5ea27 100644
--- a/drivers/media/video/ov2640.c
+++ b/drivers/media/video/ov2640.c
@@ -701,44 +701,6 @@ static int ov2640_s_stream(struct v4l2_subdev *sd, int enable)
701 return 0; 701 return 0;
702} 702}
703 703
704static int ov2640_set_bus_param(struct soc_camera_device *icd,
705 unsigned long flags)
706{
707 struct soc_camera_link *icl = to_soc_camera_link(icd);
708 unsigned long width_flag = flags & SOCAM_DATAWIDTH_MASK;
709
710 /* Only one width bit may be set */
711 if (!is_power_of_2(width_flag))
712 return -EINVAL;
713
714 if (icl->set_bus_param)
715 return icl->set_bus_param(icl, width_flag);
716
717 /*
718 * Without board specific bus width settings we support only the
719 * sensors native bus width witch are tested working
720 */
721 if (width_flag & (SOCAM_DATAWIDTH_10 | SOCAM_DATAWIDTH_8))
722 return 0;
723
724 return 0;
725}
726
727static unsigned long ov2640_query_bus_param(struct soc_camera_device *icd)
728{
729 struct soc_camera_link *icl = to_soc_camera_link(icd);
730 unsigned long flags = SOCAM_PCLK_SAMPLE_RISING | SOCAM_MASTER |
731 SOCAM_VSYNC_ACTIVE_HIGH | SOCAM_HSYNC_ACTIVE_HIGH |
732 SOCAM_DATA_ACTIVE_HIGH;
733
734 if (icl->query_bus_param)
735 flags |= icl->query_bus_param(icl) & SOCAM_DATAWIDTH_MASK;
736 else
737 flags |= SOCAM_DATAWIDTH_10;
738
739 return soc_camera_apply_sensor_flags(icl, flags);
740}
741
742static int ov2640_g_ctrl(struct v4l2_subdev *sd, struct v4l2_control *ctrl) 704static int ov2640_g_ctrl(struct v4l2_subdev *sd, struct v4l2_control *ctrl)
743{ 705{
744 struct i2c_client *client = v4l2_get_subdevdata(sd); 706 struct i2c_client *client = v4l2_get_subdevdata(sd);
@@ -1067,8 +1029,6 @@ err:
1067} 1029}
1068 1030
1069static struct soc_camera_ops ov2640_ops = { 1031static struct soc_camera_ops ov2640_ops = {
1070 .set_bus_param = ov2640_set_bus_param,
1071 .query_bus_param = ov2640_query_bus_param,
1072 .controls = ov2640_controls, 1032 .controls = ov2640_controls,
1073 .num_controls = ARRAY_SIZE(ov2640_controls), 1033 .num_controls = ARRAY_SIZE(ov2640_controls),
1074}; 1034};