From: Laurent Pinchart Date: Sun, 24 Sep 2023 15:32:54 +0000 (+0300) Subject: media: i2c: imx219: Fix test pattern window for 640x480 mode X-Git-Tag: v6.7-rc1~51^2~108 X-Git-Url: https://git.kernel.dk/?a=commitdiff_plain;h=55c3ec033b7e3353d1bed7ab96de8e9abc02fe3a;p=linux-2.6-block.git media: i2c: imx219: Fix test pattern window for 640x480 mode The 640x480 mode specifies incorrect values for the TP_WINDOW_WIDTH and TP_WINDOW_HEIGHT registers, which likely got copied from the 1640x1232 mode. They should be identical to the X_OUTPUT_SIZE and Y_OUTPUT_SIZE registers as for all the other modes, to avoid cropping the test pattern. Fix them. Signed-off-by: Laurent Pinchart Reviewed-by: Dave Stevenson Signed-off-by: Sakari Ailus Signed-off-by: Hans Verkuil --- diff --git a/drivers/media/i2c/imx219.c b/drivers/media/i2c/imx219.c index a14de8f3dee7..cf55c59cbb7f 100644 --- a/drivers/media/i2c/imx219.c +++ b/drivers/media/i2c/imx219.c @@ -263,8 +263,8 @@ static const struct cci_reg_sequence mode_640_480_regs[] = { { IMX219_REG_Y_ADD_END_A, 1711 }, { IMX219_REG_X_OUTPUT_SIZE, 640 }, { IMX219_REG_Y_OUTPUT_SIZE, 480 }, - { IMX219_REG_TP_WINDOW_WIDTH, 1640 }, - { IMX219_REG_TP_WINDOW_HEIGHT, 1232 }, + { IMX219_REG_TP_WINDOW_WIDTH, 640 }, + { IMX219_REG_TP_WINDOW_HEIGHT, 480 }, }; static const struct cci_reg_sequence raw8_framefmt_regs[] = {