media: i2c: imx307 fix compile error

Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
Change-Id: I8327261ab82f84329ebb65f54fea396640a44b15
This commit is contained in:
Zefa Chen
2021-09-08 16:29:50 +08:00
parent 84d1fcadf6
commit 95ffa7ac25
3 changed files with 15 additions and 3 deletions

View File

@@ -911,6 +911,17 @@ config VIDEO_IMX290
To compile this driver as a module, choose M here: the
module will be called imx290.
config VIDEO_IMX307
tristate "Sony IMX307 sensor support"
depends on I2C && VIDEO_V4L2 && VIDEO_V4L2_SUBDEV_API
depends on MEDIA_CAMERA_SUPPORT
help
This is a Video4Linux2 sensor driver for the Sony
IMX307 camera.
To compile this driver as a module, choose M here: the
module will be called imx307.
config VIDEO_IMX319
tristate "Sony IMX319 sensor support"
depends on I2C && VIDEO_V4L2

View File

@@ -127,6 +127,7 @@ obj-$(CONFIG_VIDEO_IMX219) += imx219.o
obj-$(CONFIG_VIDEO_IMX258) += imx258.o
obj-$(CONFIG_VIDEO_IMX274) += imx274.o
obj-$(CONFIG_VIDEO_IMX290) += imx290.o
obj-$(CONFIG_VIDEO_IMX307) += imx307.o
obj-$(CONFIG_VIDEO_IMX319) += imx319.o
obj-$(CONFIG_VIDEO_IMX355) += imx355.o
obj-$(CONFIG_VIDEO_MAX9286) += max9286.o

View File

@@ -1194,7 +1194,7 @@ static int imx307_g_frame_interval(struct v4l2_subdev *sd,
return 0;
}
static int imx307_g_mbus_config(struct v4l2_subdev *sd,
static int imx307_g_mbus_config(struct v4l2_subdev *sd, unsigned int pad_id,
struct v4l2_mbus_config *config)
{
struct imx307 *imx307 = to_imx307(sd);
@@ -1206,7 +1206,7 @@ static int imx307_g_mbus_config(struct v4l2_subdev *sd,
if (imx307->bus_cfg.bus_type == 3)
config->type = V4L2_MBUS_CCP2;
else
config->type = V4L2_MBUS_CSI2;
config->type = V4L2_MBUS_CSI2_DPHY;
config->flags = val;
return 0;
@@ -1918,7 +1918,6 @@ static const struct v4l2_subdev_core_ops imx307_core_ops = {
static const struct v4l2_subdev_video_ops imx307_video_ops = {
.s_stream = imx307_s_stream,
.g_frame_interval = imx307_g_frame_interval,
.g_mbus_config = imx307_g_mbus_config,
};
static const struct v4l2_subdev_pad_ops imx307_pad_ops = {
@@ -1928,6 +1927,7 @@ static const struct v4l2_subdev_pad_ops imx307_pad_ops = {
.get_fmt = imx307_get_fmt,
.set_fmt = imx307_set_fmt,
.get_selection = imx307_get_selection,
.get_mbus_config = imx307_g_mbus_config,
};
static const struct v4l2_subdev_ops imx307_subdev_ops = {