summaryrefslogtreecommitdiffstats
path: root/drivers/media/i2c/ov5640.c
diff options
context:
space:
mode:
authorSakari Ailus2018-07-03 23:19:27 +0200
committerMauro Carvalho Chehab2018-10-04 22:06:15 +0200
commit2d95e7ed07ed29715a801a3d33b2ad2a6fb26ee3 (patch)
tree5054993a2a98cd1552749cbdb8b006d32409c4d3 /drivers/media/i2c/ov5640.c
parentmedia: v4l: fwnode: Add definitions for CSI-2 D-PHY, parallel and Bt.656 busses (diff)
downloadkernel-qcow2-linux-2d95e7ed07ed29715a801a3d33b2ad2a6fb26ee3.tar.gz
kernel-qcow2-linux-2d95e7ed07ed29715a801a3d33b2ad2a6fb26ee3.tar.xz
kernel-qcow2-linux-2d95e7ed07ed29715a801a3d33b2ad2a6fb26ee3.zip
media: v4l: mediabus: Recognise CSI-2 D-PHY and C-PHY
The CSI-2 bus may use either D-PHY or C-PHY. Make this visible in media bus enum. Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Tested-by: Steve Longerbeam <steve_longerbeam@mentor.com> Tested-by: Jacopo Mondi <jacopo+renesas@jmondi.org> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Diffstat (limited to 'drivers/media/i2c/ov5640.c')
-rw-r--r--drivers/media/i2c/ov5640.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/media/i2c/ov5640.c b/drivers/media/i2c/ov5640.c
index 664ffacc8d66..73a4bd7c0291 100644
--- a/drivers/media/i2c/ov5640.c
+++ b/drivers/media/i2c/ov5640.c
@@ -1820,7 +1820,7 @@ static int ov5640_set_power(struct ov5640_dev *sensor, bool on)
goto power_off;
/* We're done here for DVP bus, while CSI-2 needs setup. */
- if (sensor->ep.bus_type != V4L2_MBUS_CSI2)
+ if (sensor->ep.bus_type != V4L2_MBUS_CSI2_DPHY)
return 0;
/*
@@ -1867,7 +1867,7 @@ static int ov5640_set_power(struct ov5640_dev *sensor, bool on)
usleep_range(500, 1000);
} else {
- if (sensor->ep.bus_type == V4L2_MBUS_CSI2) {
+ if (sensor->ep.bus_type == V4L2_MBUS_CSI2_DPHY) {
/* Reset MIPI bus settings to their default values. */
ov5640_write_reg(sensor,
OV5640_REG_IO_MIPI_CTRL00, 0x58);
@@ -2625,7 +2625,7 @@ static int ov5640_s_stream(struct v4l2_subdev *sd, int enable)
sensor->pending_fmt_change = false;
}
- if (sensor->ep.bus_type == V4L2_MBUS_CSI2)
+ if (sensor->ep.bus_type == V4L2_MBUS_CSI2_DPHY)
ret = ov5640_set_stream_mipi(sensor, enable);
else
ret = ov5640_set_stream_dvp(sensor, enable);