media: imx296: Fix Bayer order
authorNaushir Patuck <naush@raspberrypi.com>
Tue, 17 May 2022 11:58:37 +0000 (12:58 +0100)
committerPhil Elwell <8911409+pelwell@users.noreply.github.com>
Fri, 20 May 2022 15:12:36 +0000 (16:12 +0100)
Switch the Bayer ordering advertised by the device driver from BGGR to RGGB.

Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
drivers/media/i2c/imx296.c

index 4be0318..3394415 100644 (file)
@@ -610,7 +610,7 @@ static int imx296_enum_mbus_code(struct v4l2_subdev *sd,
                return -EINVAL;
 
        code->code = sensor->mono ? MEDIA_BUS_FMT_Y10_1X10
-                  : MEDIA_BUS_FMT_SBGGR10_1X10;
+                  : MEDIA_BUS_FMT_SRGGB10_1X10;
 
        return 0;
 }
@@ -715,7 +715,7 @@ static int imx296_set_format(struct v4l2_subdev *sd,
        }
 
        format->code = sensor->mono ? MEDIA_BUS_FMT_Y10_1X10
-                    : MEDIA_BUS_FMT_SBGGR10_1X10;
+                    : MEDIA_BUS_FMT_SRGGB10_1X10;
        format->field = V4L2_FIELD_NONE;
        format->colorspace = V4L2_COLORSPACE_RAW;
        format->ycbcr_enc = V4L2_YCBCR_ENC_DEFAULT;