diff options
author | Hans Verkuil <hverkuil@xs4all.nl> | 2018-02-02 08:00:32 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@s-opensource.com> | 2018-02-26 09:31:11 -0500 |
commit | 3da7ee94f3fe9a58c9a7ddd6f5c892524068780c (patch) | |
tree | bf224f8eab4d720c36736fdbc7fe69c5a6b24a3e /drivers/media/platform/vimc/vimc-common.c | |
parent | 876e32e5dd6e08320288862440e3e8a9542b5d9b (diff) | |
download | lwn-3da7ee94f3fe9a58c9a7ddd6f5c892524068780c.tar.gz lwn-3da7ee94f3fe9a58c9a7ddd6f5c892524068780c.zip |
media: vimc: fix control event handling
The sensor subdev didn't handle control events. Add support for this.
Found with v4l2-compliance.
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Diffstat (limited to 'drivers/media/platform/vimc/vimc-common.c')
-rw-r--r-- | drivers/media/platform/vimc/vimc-common.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/media/platform/vimc/vimc-common.c b/drivers/media/platform/vimc/vimc-common.c index 9d63c84a9876..617415c224fe 100644 --- a/drivers/media/platform/vimc/vimc-common.c +++ b/drivers/media/platform/vimc/vimc-common.c @@ -434,7 +434,9 @@ int vimc_ent_sd_register(struct vimc_ent_device *ved, v4l2_set_subdevdata(sd, ved); /* Expose this subdev to user space */ - sd->flags = V4L2_SUBDEV_FL_HAS_DEVNODE; + sd->flags |= V4L2_SUBDEV_FL_HAS_DEVNODE; + if (sd->ctrl_handler) + sd->flags |= V4L2_SUBDEV_FL_HAS_EVENTS; /* Initialize the media entity */ ret = media_entity_pads_init(&sd->entity, num_pads, ved->pads); |