Set drm_connector_hdmi_state.scrambler_needed when the computed TMDS character rate exceeds the HDMI 1.3 maximum TMDS character rate.
HDMI 2.0 requires scrambling above 340 MHz. Centralize that clock-based requirement in the HDMI state helper so drivers do not need to open-code the threshold check. Signed-off-by: Cristian Ciocaltea <[email protected]> --- drivers/gpu/drm/display/drm_hdmi_state_helper.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/display/drm_hdmi_state_helper.c b/drivers/gpu/drm/display/drm_hdmi_state_helper.c index 69ccfbf123fe..34e48e04d971 100644 --- a/drivers/gpu/drm/display/drm_hdmi_state_helper.c +++ b/drivers/gpu/drm/display/drm_hdmi_state_helper.c @@ -592,6 +592,7 @@ hdmi_compute_clock(const struct drm_connector *connector, return -EINVAL; conn_state->hdmi.tmds_char_rate = clock; + conn_state->hdmi.scrambler_needed = (clock > HDMI_1_3_TMDS_CHAR_RATE_MAX_HZ); return 0; } -- 2.54.0
