diff options
author | 2023-05-29 11:37:36 +0100 | |
---|---|---|
committer | 2023-06-09 15:33:09 +0100 | |
commit | a08183b8460e4800c186b754026b6fd937370871 (patch) | |
tree | 8e64aaab1874c58cff7561951dbc57e05fc9c897 /drivers/staging/media/atomisp/pci/atomisp_ioctl.c | |
parent | media: atomisp: Add support for sensors which implement selection API / cropping (diff) | |
download | wireguard-linux-a08183b8460e4800c186b754026b6fd937370871.tar.xz wireguard-linux-a08183b8460e4800c186b754026b6fd937370871.zip |
media: atomisp: Pass MEDIA_BUS_FMT_* code when calling enum_frame_size pad-op
A sensor driver's enum_frame_size pad-op may return -EINVAL when
v4l2_subdev_frame_size_enum.code is not set to a supported
MEDIA_BUS_FMT_* code.
Make atomisp_init_sensor() get the sensor's MEDIA_BUS_FMT_* code and
pass this when calling the enum_frame_size pad-op.
Link: https://lore.kernel.org/r/20230529103741.11904-17-hdegoede@redhat.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Diffstat (limited to 'drivers/staging/media/atomisp/pci/atomisp_ioctl.c')
-rw-r--r-- | drivers/staging/media/atomisp/pci/atomisp_ioctl.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/staging/media/atomisp/pci/atomisp_ioctl.c b/drivers/staging/media/atomisp/pci/atomisp_ioctl.c index 446297fef861..c5465b28a65d 100644 --- a/drivers/staging/media/atomisp/pci/atomisp_ioctl.c +++ b/drivers/staging/media/atomisp/pci/atomisp_ioctl.c @@ -707,6 +707,7 @@ static int atomisp_enum_framesizes(struct file *file, void *priv, struct v4l2_subdev_frame_size_enum fse = { .index = fsize->index, .which = V4L2_SUBDEV_FORMAT_ACTIVE, + .code = input->code, }; int ret; |