aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeil Armstrong <narmstrong@baylibre.com>2019-03-20 04:11:10 -0400
committerNeil Armstrong <narmstrong@baylibre.com>2019-03-25 06:19:50 -0400
commit3d565a21f2ce1f37479e91914734478c39b5c6fc (patch)
tree50cf860cc67e422c1ddeac3cbad704424825882f
parent2d8f92897ad816f5dda54b2ed2fd9f2d7cb1abde (diff)
drm/meson: fix TMDS clock filtering for DMT monitors
DMT monitors does not necessarely report a maximum TMDS clock in a VSDB EDID extension. In this case, all modes are wrongly rejected, including the DRM fallback EDID. This patch only rejects modes whith clock > max_tmds_clock if the max_tmds_clock is specified. This will only reject 4:2:0 HDMI2.0 modes, who reports a clock > max_tmds_clock. Reported-by: Maxime Jourdan <mjourdan@baylibre.com> Fixes: d7d8fb7046b6 ("drm/meson: add HDMI div40 TMDS mode") Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> Tested-by: Maxime Jourdan <mjourdan@baylibre.com> Reviewed-by: Maxime Jourdan <mjourdan@baylibre.com> Link: https://patchwork.freedesktop.org/patch/msgid/20190320081110.1718-1-narmstrong@baylibre.com
-rw-r--r--drivers/gpu/drm/meson/meson_dw_hdmi.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/gpu/drm/meson/meson_dw_hdmi.c b/drivers/gpu/drm/meson/meson_dw_hdmi.c
index e28814f4ea6c..563953ec6ad0 100644
--- a/drivers/gpu/drm/meson/meson_dw_hdmi.c
+++ b/drivers/gpu/drm/meson/meson_dw_hdmi.c
@@ -569,7 +569,8 @@ dw_hdmi_mode_valid(struct drm_connector *connector,
569 DRM_DEBUG_DRIVER("Modeline " DRM_MODE_FMT "\n", DRM_MODE_ARG(mode)); 569 DRM_DEBUG_DRIVER("Modeline " DRM_MODE_FMT "\n", DRM_MODE_ARG(mode));
570 570
571 /* If sink max TMDS clock, we reject the mode */ 571 /* If sink max TMDS clock, we reject the mode */
572 if (mode->clock > connector->display_info.max_tmds_clock) 572 if (connector->display_info.max_tmds_clock &&
573 mode->clock > connector->display_info.max_tmds_clock)
573 return MODE_BAD; 574 return MODE_BAD;
574 575
575 /* Check against non-VIC supported modes */ 576 /* Check against non-VIC supported modes */