Message ID | 20250724065256.75175-3-dan.scally@ideasonboard.com |
---|---|
State | New |
Headers | show |
Series |
|
Related | show |
Quoting Daniel Scally (2025-07-24 07:52:48) > Add entries to drm_fourcc.h for bayer order agnostic RAW formats at > 10, 12, 14 and 20 bits. Add a modifier for the CRU format packing. > These will need to be applied upstream, at which stage the script > can maintain their presence here. > Is there any upstream reference yet? Or are these not posted yet ? > Signed-off-by: Daniel Scally <dan.scally@ideasonboard.com> > --- > include/linux/drm_fourcc.h | 9 +++++++++ > 1 file changed, 9 insertions(+) > > diff --git a/include/linux/drm_fourcc.h b/include/linux/drm_fourcc.h > index db679877..7257f623 100644 > --- a/include/linux/drm_fourcc.h > +++ b/include/linux/drm_fourcc.h > @@ -447,18 +447,21 @@ extern "C" { > #define DRM_FORMAT_SGRBG10 fourcc_code('B', 'A', '1', '0') > #define DRM_FORMAT_SGBRG10 fourcc_code('G', 'B', '1', '0') > #define DRM_FORMAT_SBGGR10 fourcc_code('B', 'G', '1', '0') > +#define DRM_FORMAT_RAW10 fourcc_code('R', 'W', '1', '0') > > /* 12-bit Bayer formats */ > #define DRM_FORMAT_SRGGB12 fourcc_code('R', 'G', '1', '2') > #define DRM_FORMAT_SGRBG12 fourcc_code('B', 'A', '1', '2') > #define DRM_FORMAT_SGBRG12 fourcc_code('G', 'B', '1', '2') > #define DRM_FORMAT_SBGGR12 fourcc_code('B', 'G', '1', '2') > +#define DRM_FORMAT_RAW12 fourcc_code('R', 'W', '1', '2') > > /* 14-bit Bayer formats */ > #define DRM_FORMAT_SRGGB14 fourcc_code('R', 'G', '1', '4') > #define DRM_FORMAT_SGRBG14 fourcc_code('B', 'A', '1', '4') > #define DRM_FORMAT_SGBRG14 fourcc_code('G', 'B', '1', '4') > #define DRM_FORMAT_SBGGR14 fourcc_code('B', 'G', '1', '4') > +#define DRM_FORMAT_RAW14 fourcc_code('R', 'W', '1', '4') > > /* 16-bit Bayer formats */ > #define DRM_FORMAT_SRGGB16 fourcc_code('R', 'G', 'B', '6') > @@ -466,6 +469,9 @@ extern "C" { > #define DRM_FORMAT_SGBRG16 fourcc_code('G', 'B', '1', '6') > #define DRM_FORMAT_SBGGR16 fourcc_code('B', 'Y', 'R', '2') > > +/* 20-bit Bayer formats */ > +#define DRM_FORMAT_RAW20 fourcc_code('R', 'W', '2', '0') > + > /* > * Format Modifiers: > * > @@ -491,6 +497,7 @@ extern "C" { > #define DRM_FORMAT_MOD_VENDOR_AMLOGIC 0x0a > #define DRM_FORMAT_MOD_VENDOR_MIPI 0x0b > #define DRM_FORMAT_MOD_VENDOR_RPI 0x0c > +#define DRM_FORMAT_MOD_VENDOR_RENESAS 0x0d > > /* add more to the end as needed */ > > @@ -1692,6 +1699,8 @@ drm_fourcc_canonicalize_nvidia_format_mod(__u64 modifier) > #define PISP_FORMAT_MOD_COMPRESS_MODE1 fourcc_mod_code(RPI, 1) > #define PISP_FORMAT_MOD_COMPRESS_MODE2 fourcc_mod_code(RPI, 2) > > +#define RENESAS_CRU_FORMAT_MOD_PACKED fourcc_mod_code(RENESAS, 1) > + > #if defined(__cplusplus) > } > #endif > -- > 2.30.2 >
diff --git a/include/linux/drm_fourcc.h b/include/linux/drm_fourcc.h index db679877..7257f623 100644 --- a/include/linux/drm_fourcc.h +++ b/include/linux/drm_fourcc.h @@ -447,18 +447,21 @@ extern "C" { #define DRM_FORMAT_SGRBG10 fourcc_code('B', 'A', '1', '0') #define DRM_FORMAT_SGBRG10 fourcc_code('G', 'B', '1', '0') #define DRM_FORMAT_SBGGR10 fourcc_code('B', 'G', '1', '0') +#define DRM_FORMAT_RAW10 fourcc_code('R', 'W', '1', '0') /* 12-bit Bayer formats */ #define DRM_FORMAT_SRGGB12 fourcc_code('R', 'G', '1', '2') #define DRM_FORMAT_SGRBG12 fourcc_code('B', 'A', '1', '2') #define DRM_FORMAT_SGBRG12 fourcc_code('G', 'B', '1', '2') #define DRM_FORMAT_SBGGR12 fourcc_code('B', 'G', '1', '2') +#define DRM_FORMAT_RAW12 fourcc_code('R', 'W', '1', '2') /* 14-bit Bayer formats */ #define DRM_FORMAT_SRGGB14 fourcc_code('R', 'G', '1', '4') #define DRM_FORMAT_SGRBG14 fourcc_code('B', 'A', '1', '4') #define DRM_FORMAT_SGBRG14 fourcc_code('G', 'B', '1', '4') #define DRM_FORMAT_SBGGR14 fourcc_code('B', 'G', '1', '4') +#define DRM_FORMAT_RAW14 fourcc_code('R', 'W', '1', '4') /* 16-bit Bayer formats */ #define DRM_FORMAT_SRGGB16 fourcc_code('R', 'G', 'B', '6') @@ -466,6 +469,9 @@ extern "C" { #define DRM_FORMAT_SGBRG16 fourcc_code('G', 'B', '1', '6') #define DRM_FORMAT_SBGGR16 fourcc_code('B', 'Y', 'R', '2') +/* 20-bit Bayer formats */ +#define DRM_FORMAT_RAW20 fourcc_code('R', 'W', '2', '0') + /* * Format Modifiers: * @@ -491,6 +497,7 @@ extern "C" { #define DRM_FORMAT_MOD_VENDOR_AMLOGIC 0x0a #define DRM_FORMAT_MOD_VENDOR_MIPI 0x0b #define DRM_FORMAT_MOD_VENDOR_RPI 0x0c +#define DRM_FORMAT_MOD_VENDOR_RENESAS 0x0d /* add more to the end as needed */ @@ -1692,6 +1699,8 @@ drm_fourcc_canonicalize_nvidia_format_mod(__u64 modifier) #define PISP_FORMAT_MOD_COMPRESS_MODE1 fourcc_mod_code(RPI, 1) #define PISP_FORMAT_MOD_COMPRESS_MODE2 fourcc_mod_code(RPI, 2) +#define RENESAS_CRU_FORMAT_MOD_PACKED fourcc_mod_code(RENESAS, 1) + #if defined(__cplusplus) } #endif
Add entries to drm_fourcc.h for bayer order agnostic RAW formats at 10, 12, 14 and 20 bits. Add a modifier for the CRU format packing. These will need to be applied upstream, at which stage the script can maintain their presence here. Signed-off-by: Daniel Scally <dan.scally@ideasonboard.com> --- include/linux/drm_fourcc.h | 9 +++++++++ 1 file changed, 9 insertions(+)