From b1d8b2c24d2bd69d4c17a0611bf1fc366dd63689 Mon Sep 17 00:00:00 2001 From: Algea Cao Date: Wed, 23 Aug 2023 14:55:57 +0800 Subject: [PATCH] drm/bridge: synopsys: dw-hdmi-qp: Fix frl switch error when switching resolution and color at the same time When switching resolution and color at same commit, current judgment conditions will cause the hdmi switching process will not run properly if switching from tmds resolution to frl resolution. So we need to add the judgment of the resolution before and after the switch. Change-Id: I96e304acf224bcfd01edba9df64a3d6b96a2c90d Signed-off-by: Algea Cao --- drivers/gpu/drm/bridge/synopsys/dw-hdmi-qp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/bridge/synopsys/dw-hdmi-qp.c b/drivers/gpu/drm/bridge/synopsys/dw-hdmi-qp.c index 96c510111f36..e234228adf88 100644 --- a/drivers/gpu/drm/bridge/synopsys/dw-hdmi-qp.c +++ b/drivers/gpu/drm/bridge/synopsys/dw-hdmi-qp.c @@ -2597,7 +2597,7 @@ static int dw_hdmi_connector_atomic_check(struct drm_connector *connector, hdmi_modb(hdmi, PKTSCHED_GCP_TX_EN, PKTSCHED_GCP_TX_EN, PKTSCHED_PKT_EN); mdelay(50); } else if (!hdmi->disabled) { - if (mode.clock > 600000) + if (hdmi->previous_mode.clock > 600000 && mode.clock > 600000) hdmi->frl_switch = true; hdmi->update = false; crtc_state->mode_changed = true;