linux/drivers/media/test-drivers
Arash Golgol ad4c65fa30 media: vimc: fix pixel format lookup in enum_framesizes
vimc_capture_enum_framesizes() looks up the requested format using
vimc_pix_map_by_code(), which searches the pix map table by media
bus code (MEDIA_BUS_FMT_*).

However, v4l2_frmsizeenum::pixel_format holds a V4L2 pixel format
(V4L2_PIX_FMT_*), not a media bus code, so valid pixel formats end
up being rejected with -EINVAL.

Fix this by using vimc_pix_map_by_pixelformat() instead, which
performs the lookup by pixel format as the ioctl expects.

Fixes: 09c41a23a2 ("media: Revert "media: vimc: propagate pixel format in the stream"")
Cc: stable@vger.kernel.org
Signed-off-by: Arash Golgol <arash.golgol@gmail.com>
Signed-off-by: Hans Verkuil <hverkuil+cisco@kernel.org>
2026-07-28 15:17:54 +02:00
..
vicodec media: vicodec: fix out-of-bounds write in FWHT encoder 2026-07-15 15:31:24 +02:00
vidtv media: Use named initializers for arrays of i2c_device_data 2026-05-20 09:03:40 +02:00
vimc media: vimc: fix pixel format lookup in enum_framesizes 2026-07-28 15:17:54 +02:00
visl media: visl: check if ctx->tpg_str_buf allocation failed 2026-05-12 09:39:03 +02:00
vivid media: vivid: always allow meta output streaming 2026-07-17 10:13:47 +02:00
Kconfig media: drop CONFIG_MEDIA_CONTROLLER_REQUEST_API 2023-11-23 13:03:45 +01:00
Makefile media: visl: add virtual stateless decoder driver 2022-11-25 07:32:16 +00:00
vim2m.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00