linux (Rockchip): rebase patches for 5.10.159

updated based on:
- drm: bridge: dw_hdmi: fix preference of RGB modes over YUV420
- d3d6b1bf85
This commit is contained in:
Rudi Heitbaum 2022-12-12 05:02:16 +00:00
parent de9d3a1c39
commit 1c500f2f17

View File

@ -2146,6 +2146,11 @@ index ab2a97574fa7..b382fc2f8156 100644
@@ -2620,40 +2632,51 @@ static u32 *dw_hdmi_bridge_atomic_get_output_bus_fmts(struct drm_bridge *bridge, @@ -2620,40 +2632,51 @@ static u32 *dw_hdmi_bridge_atomic_get_output_bus_fmts(struct drm_bridge *bridge,
*/ */
/* Default 8bit RGB fallback */
- output_fmts[i++] = MEDIA_BUS_FMT_RGB888_1X24;
+ if (is_tmds_allowed(info, mode, MEDIA_BUS_FMT_RGB888_1X24))
+ output_fmts[i++] = MEDIA_BUS_FMT_RGB888_1X24;
if (max_bpc >= 16 && info->bpc == 16) { if (max_bpc >= 16 && info->bpc == 16) {
- if (info->color_formats & DRM_COLOR_FORMAT_YCRCB444) - if (info->color_formats & DRM_COLOR_FORMAT_YCRCB444)
+ if ((info->color_formats & DRM_COLOR_FORMAT_YCRCB444) && + if ((info->color_formats & DRM_COLOR_FORMAT_YCRCB444) &&
@ -2199,11 +2204,6 @@ index ab2a97574fa7..b382fc2f8156 100644
+ is_tmds_allowed(info, mode, MEDIA_BUS_FMT_YUV8_1X24)) + is_tmds_allowed(info, mode, MEDIA_BUS_FMT_YUV8_1X24))
output_fmts[i++] = MEDIA_BUS_FMT_YUV8_1X24; output_fmts[i++] = MEDIA_BUS_FMT_YUV8_1X24;
/* Default 8bit RGB fallback */
- output_fmts[i++] = MEDIA_BUS_FMT_RGB888_1X24;
+ if (is_tmds_allowed(info, mode, MEDIA_BUS_FMT_RGB888_1X24))
+ output_fmts[i++] = MEDIA_BUS_FMT_RGB888_1X24;
*num_output_fmts = i; *num_output_fmts = i;
@@ -2833,11 +2856,20 @@ dw_hdmi_bridge_mode_valid(struct drm_bridge *bridge, @@ -2833,11 +2856,20 @@ dw_hdmi_bridge_mode_valid(struct drm_bridge *bridge,