Re: [PATCH v2 5/8] media: qcom: camss: Add CSID gen3 driver

From: Bryan O'Donoghue
Date: Wed Mar 20 2024 - 12:12:50 EST


On 20/03/2024 15:40, Bryan O'Donoghue wrote:
+static const struct csid_format csid_formats[] = {
+    {
+        MEDIA_BUS_FMT_UYVY8_1X16,
+        DATA_TYPE_YUV422_8BIT,
+        DECODE_FORMAT_UNCOMPRESSED_8_BIT,
+        8,
+        2,
+    },
+    {
+        MEDIA_BUS_FMT_VYUY8_1X16,
+        DATA_TYPE_YUV422_8BIT,
+        DECODE_FORMAT_UNCOMPRESSED_8_BIT,
+        8,
+        2,
+    },
+    {
+        MEDIA_BUS_FMT_YUYV8_1X16,
+        DATA_TYPE_YUV422_8BIT,
+        DECODE_FORMAT_UNCOMPRESSED_8_BIT,
+        8,
+        2,
+    },
+    {
+        MEDIA_BUS_FMT_YVYU8_1X16,
+        DATA_TYPE_YUV422_8BIT,
+        DECODE_FORMAT_UNCOMPRESSED_8_BIT,
+        8,
+        2,
+    },
+    {
+        MEDIA_BUS_FMT_SBGGR8_1X8,
+        DATA_TYPE_RAW_8BIT,
+        DECODE_FORMAT_UNCOMPRESSED_8_BIT,
+        8,
+        1,
+    },
+    {
+        MEDIA_BUS_FMT_SGBRG8_1X8,
+        DATA_TYPE_RAW_8BIT,
+        DECODE_FORMAT_UNCOMPRESSED_8_BIT,
+        8,
+        1,
+    },
+    {
+        MEDIA_BUS_FMT_SGRBG8_1X8,
+        DATA_TYPE_RAW_8BIT,
+        DECODE_FORMAT_UNCOMPRESSED_8_BIT,
+        8,
+        1,
+    },
+    {
+        MEDIA_BUS_FMT_SRGGB8_1X8,
+        DATA_TYPE_RAW_8BIT,
+        DECODE_FORMAT_UNCOMPRESSED_8_BIT,
+        8,
+        1,
+    },
+    {
+        MEDIA_BUS_FMT_SBGGR10_1X10,
+        DATA_TYPE_RAW_10BIT,
+        DECODE_FORMAT_UNCOMPRESSED_10_BIT,
+        10,
+        1,
+    },
+    {
+        MEDIA_BUS_FMT_SGBRG10_1X10,
+        DATA_TYPE_RAW_10BIT,
+        DECODE_FORMAT_UNCOMPRESSED_10_BIT,
+        10,
+        1,
+    },
+    {
+        MEDIA_BUS_FMT_SGRBG10_1X10,
+        DATA_TYPE_RAW_10BIT,
+        DECODE_FORMAT_UNCOMPRESSED_10_BIT,
+        10,
+        1,
+    },
+    {
+        MEDIA_BUS_FMT_SRGGB10_1X10,
+        DATA_TYPE_RAW_10BIT,
+        DECODE_FORMAT_UNCOMPRESSED_10_BIT,
+        10,
+        1,
+    },
+    {
+        MEDIA_BUS_FMT_Y8_1X8,
+        DATA_TYPE_RAW_8BIT,
+        DECODE_FORMAT_UNCOMPRESSED_8_BIT,
+        8,
+        1,
+    },
+    {
+        MEDIA_BUS_FMT_Y10_1X10,
+        DATA_TYPE_RAW_10BIT,
+        DECODE_FORMAT_UNCOMPRESSED_10_BIT,
+        10,
+        1,
+    },
+    {
+        MEDIA_BUS_FMT_SBGGR12_1X12,
+        DATA_TYPE_RAW_12BIT,
+        DECODE_FORMAT_UNCOMPRESSED_12_BIT,
+        12,
+        1,
+    },
+    {
+        MEDIA_BUS_FMT_SGBRG12_1X12,
+        DATA_TYPE_RAW_12BIT,
+        DECODE_FORMAT_UNCOMPRESSED_12_BIT,
+        12,
+        1,
+    },
+    {
+        MEDIA_BUS_FMT_SGRBG12_1X12,
+        DATA_TYPE_RAW_12BIT,
+        DECODE_FORMAT_UNCOMPRESSED_12_BIT,
+        12,
+        1,
+    },
+    {
+        MEDIA_BUS_FMT_SRGGB12_1X12,
+        DATA_TYPE_RAW_12BIT,
+        DECODE_FORMAT_UNCOMPRESSED_12_BIT,
+        12,
+        1,
+    },
+    {
+        MEDIA_BUS_FMT_SBGGR14_1X14,
+        DATA_TYPE_RAW_14BIT,
+        DECODE_FORMAT_UNCOMPRESSED_14_BIT,
+        14,
+        1,
+    },
+    {
+        MEDIA_BUS_FMT_SGBRG14_1X14,
+        DATA_TYPE_RAW_14BIT,
+        DECODE_FORMAT_UNCOMPRESSED_14_BIT,
+        14,
+        1,
+    },
+    {
+        MEDIA_BUS_FMT_SGRBG14_1X14,
+        DATA_TYPE_RAW_14BIT,
+        DECODE_FORMAT_UNCOMPRESSED_14_BIT,
+        14,
+        1,
+    },
+    {
+        MEDIA_BUS_FMT_SRGGB14_1X14,
+        DATA_TYPE_RAW_14BIT,
+        DECODE_FORMAT_UNCOMPRESSED_14_BIT,
+        14,
+        1,
+    },
+};

Also please consider including/reviewing Gjorgji's patchset which reworks the declaration of resources.

https://lore.kernel.org/lkml/20240319173935.481-4-quic_grosikop@xxxxxxxxxxx/T/

---
bod