From ba533bb043a8af516f863d5319daa57ec475c178 Mon Sep 17 00:00:00 2001 From: Dave Stevenson Date: Wed, 15 Jul 2026 12:43:28 +0100 Subject: [PATCH] media: imx355: Set the colorspace in the format The colorspace fields were left set to 0 when they should be set appropriately for a raw image sensor. Add those values. Signed-off-by: Dave Stevenson Signed-off-by: Sakari Ailus --- drivers/media/i2c/imx355.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/drivers/media/i2c/imx355.c b/drivers/media/i2c/imx355.c index 52bdfe636231..fa8a6851b44e 100644 --- a/drivers/media/i2c/imx355.c +++ b/drivers/media/i2c/imx355.c @@ -612,6 +612,10 @@ static int imx355_open(struct v4l2_subdev *sd, struct v4l2_subdev_fh *fh) try_fmt->height = imx355->cur_mode->height; try_fmt->code = imx355_get_format_code(imx355); try_fmt->field = V4L2_FIELD_NONE; + try_fmt->colorspace = V4L2_COLORSPACE_RAW; + try_fmt->ycbcr_enc = V4L2_YCBCR_ENC_601; + try_fmt->quantization = V4L2_QUANTIZATION_FULL_RANGE; + try_fmt->xfer_func = V4L2_XFER_FUNC_NONE; *crop = imx355->cur_mode->crop; @@ -738,6 +742,10 @@ static void imx355_update_pad_format(struct imx355 *imx355, fmt->format.height = mode->height; fmt->format.code = imx355_get_format_code(imx355); fmt->format.field = V4L2_FIELD_NONE; + fmt->format.colorspace = V4L2_COLORSPACE_RAW; + fmt->format.ycbcr_enc = V4L2_YCBCR_ENC_601; + fmt->format.quantization = V4L2_QUANTIZATION_FULL_RANGE; + fmt->format.xfer_func = V4L2_XFER_FUNC_NONE; } static int imx355_do_get_pad_format(struct imx355 *imx355,