Hi Jan, On 10/18/2026 8:30 PM, Jan Claußen wrote: > Expose BT.2020 RGB and YCC colorimetry so userspace can enable HDR > output. Also explicitly expose BT.709 YCC as it is listed in the > Rockchip RK3588 TRM V1.0-Part2 20220309 data sheet. > > Tested on a Radxa Rock 5B (RK3588) with an LG OLED55B87LC in KDE > Plasma 6.7.5: enabling HDR switches the colorspace to BT.2020, and > disabling it restores the default. > > Signed-off-by: Jan Claußen <[email protected]> > --- > > Not sure if BT.709 needs to be explicitly exposed here, but it is mentioned > in the data sheet. > Might be covered by DRM_MODE_COLORIMETRY_DEFAULT though.
Cc: Cristian Ciocaltea <[email protected]> Hi Cristian, may be you would be interested in this series? "DEFAULT" may refer to either BT.601 or BT.709. It should support the following color spaces: #define HDMI_COLORSPACE_CAPS_V1 (DRM_MODE_COLORIMETRY_DEFAULT | \ DRM_MODE_COLORIMETRY_SMPTE_170M_YCC | \ DRM_MODE_COLORIMETRY_BT709_YCC | \ DRM_MODE_COLORIMETRY_BT2020_RGB) #define HDMI_COLORSPACE_CAPS_V2 (HDMI_COLORSPACE_CAPS_V1 | \ DRM_MODE_COLORIMETRY_DCI_P3_RGB_D65) > > BT.709/BT.2020 YCC are untested. > > drivers/gpu/drm/rockchip/dw_hdmi_qp-rockchip.c | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/drivers/gpu/drm/rockchip/dw_hdmi_qp-rockchip.c > b/drivers/gpu/drm/rockchip/dw_hdmi_qp-rockchip.c > index 9c4cf68d79d5..dbb87dfd000c 100644 > --- a/drivers/gpu/drm/rockchip/dw_hdmi_qp-rockchip.c > +++ b/drivers/gpu/drm/rockchip/dw_hdmi_qp-rockchip.c > @@ -605,6 +605,10 @@ static int dw_hdmi_qp_rockchip_bind(struct device *dev, > struct device *master, > BIT(DRM_OUTPUT_COLOR_FORMAT_YCBCR444) | > BIT(DRM_OUTPUT_COLOR_FORMAT_YCBCR422); > > + plat_data.supported_colorspaces = BIT(DRM_MODE_COLORIMETRY_BT709_YCC) | > + BIT(DRM_MODE_COLORIMETRY_BT2020_RGB) | > + BIT(DRM_MODE_COLORIMETRY_BT2020_YCC); > + > encoder = &hdmi->encoder.encoder; > encoder->possible_crtcs = drm_of_find_possible_crtcs(drm, dev->of_node); > -- Best, Chaoyi
