]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
media: media/i2c: add missing entity functions
authorHans Verkuil <hans.verkuil@cisco.com>
Mon, 18 Jun 2018 09:10:28 +0000 (05:10 -0400)
committerMauro Carvalho Chehab <mchehab+samsung@kernel.org>
Wed, 25 Jul 2018 12:04:00 +0000 (08:04 -0400)
Several drivers in media/i2c do not set the entity function.
Correct this.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
drivers/media/i2c/et8ek8/et8ek8_driver.c
drivers/media/i2c/mt9m032.c
drivers/media/i2c/mt9p031.c
drivers/media/i2c/mt9t001.c
drivers/media/i2c/mt9v032.c

index e9eff9039ef5a8f303810ecb1fdc54cce365d3d2..37ef38947e018619978097e296e50eac8d0034ad 100644 (file)
@@ -1446,6 +1446,7 @@ static int et8ek8_probe(struct i2c_client *client,
        sensor->subdev.flags |= V4L2_SUBDEV_FL_HAS_DEVNODE;
        sensor->subdev.internal_ops = &et8ek8_internal_ops;
 
+       sensor->subdev.entity.function = MEDIA_ENT_F_CAM_SENSOR;
        sensor->pad.flags = MEDIA_PAD_FL_SOURCE;
        ret = media_entity_pads_init(&sensor->subdev.entity, 1, &sensor->pad);
        if (ret < 0) {
index 6a9e068462fd9484be7a69135af9ed8510311d63..b385f2b632adc44cf28e6d63cd459bbf15c03324 100644 (file)
@@ -793,6 +793,7 @@ static int mt9m032_probe(struct i2c_client *client,
        v4l2_ctrl_cluster(2, &sensor->hflip);
 
        sensor->subdev.ctrl_handler = &sensor->ctrls;
+       sensor->subdev.entity.function = MEDIA_ENT_F_CAM_SENSOR;
        sensor->pad.flags = MEDIA_PAD_FL_SOURCE;
        ret = media_entity_pads_init(&sensor->subdev.entity, 1, &sensor->pad);
        if (ret < 0)
index 91d822fc4443a362d3ee8d2b6538deb84b8e2f91..715be3632b01a2e78d98eea4ae7f1a5d55eefd5d 100644 (file)
@@ -1111,6 +1111,7 @@ static int mt9p031_probe(struct i2c_client *client,
        v4l2_i2c_subdev_init(&mt9p031->subdev, client, &mt9p031_subdev_ops);
        mt9p031->subdev.internal_ops = &mt9p031_subdev_internal_ops;
 
+       mt9p031->subdev.entity.function = MEDIA_ENT_F_CAM_SENSOR;
        mt9p031->pad.flags = MEDIA_PAD_FL_SOURCE;
        ret = media_entity_pads_init(&mt9p031->subdev.entity, 1, &mt9p031->pad);
        if (ret < 0)
index 9d981d9f5686f7f99bce7c01fdc36c8b6483f405..f683d2cb0486153409ec95a3dc38f153a7d4a182 100644 (file)
@@ -943,6 +943,7 @@ static int mt9t001_probe(struct i2c_client *client,
        mt9t001->subdev.internal_ops = &mt9t001_subdev_internal_ops;
        mt9t001->subdev.flags |= V4L2_SUBDEV_FL_HAS_DEVNODE;
 
+       mt9t001->subdev.entity.function = MEDIA_ENT_F_CAM_SENSOR;
        mt9t001->pad.flags = MEDIA_PAD_FL_SOURCE;
        ret = media_entity_pads_init(&mt9t001->subdev.entity, 1, &mt9t001->pad);
 
index 4de63b2df3346a8f4dc0135a5230cdfc6d17fc17..f74730d24d8fe38bf049fb3020fa5493c2f64a49 100644 (file)
@@ -1162,6 +1162,7 @@ static int mt9v032_probe(struct i2c_client *client,
        mt9v032->subdev.internal_ops = &mt9v032_subdev_internal_ops;
        mt9v032->subdev.flags |= V4L2_SUBDEV_FL_HAS_DEVNODE;
 
+       mt9v032->subdev.entity.function = MEDIA_ENT_F_CAM_SENSOR;
        mt9v032->pad.flags = MEDIA_PAD_FL_SOURCE;
        ret = media_entity_pads_init(&mt9v032->subdev.entity, 1, &mt9v032->pad);
        if (ret < 0)