@@ -390,6 +390,18 @@ static int mt9p031_set_params(struct mt9p031 *mt9p031)
return ret;
}
+static int mt9p031_g_mbus_config(struct v4l2_subdev *sd,
+ struct v4l2_mbus_config *cfg)
+{
+ cfg->type = V4L2_MBUS_PARALLEL;
+ cfg->flags = V4L2_MBUS_MASTER | V4L2_MBUS_HSYNC_ACTIVE_HIGH |
+ V4L2_MBUS_VSYNC_ACTIVE_HIGH |
+ V4L2_MBUS_PCLK_SAMPLE_FALLING |
+ V4L2_MBUS_DATA_ACTIVE_HIGH;
+
+ return 0;
+}
+
static int mt9p031_s_stream(struct v4l2_subdev *subdev, int enable)
{
struct mt9p031 *mt9p031 = to_mt9p031(subdev);
@@ -888,6 +900,7 @@ static struct v4l2_subdev_core_ops mt9p031_subdev_core_ops = {
};
static struct v4l2_subdev_video_ops mt9p031_subdev_video_ops = {
+ .g_mbus_config = mt9p031_g_mbus_config,
.s_stream = mt9p031_s_stream,
};
.g_mbus_config() subdevice video operation is required for subdevice drivers to be used with the soc-camera framework. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> --- drivers/media/i2c/mt9p031.c | 13 +++++++++++++ 1 files changed, 13 insertions(+), 0 deletions(-)