diff mbox series

[v2,01/10] drm: bridge: dw_hdmi: Disable scrambler feature when not supported

Message ID 20240908132823.3308029-2-jonas@kwiboo.se (mailing list archive)
State New, archived
Headers show
Series drm: bridge: dw_hdmi: Misc enable/disable, CEC and EDID cleanup | expand

Commit Message

Jonas Karlman Sept. 8, 2024, 1:28 p.m. UTC
The scrambler feature can be left enabled when hotplugging from a sink
and mode that require scrambling to a sink that does not support SCDC or
scrambling.

Typically a blank screen or 'no signal' message can be observed after
using a HDMI 2.0 4K@60Hz mode and then hotplugging to a sink that only
support HDMI 1.4.

Fix this by disabling the scrambler feature when SCDC is not supported.

Fixes: 264fce6cc2c1 ("drm/bridge: dw-hdmi: Add SCDC and TMDS Scrambling support")
Reported-by: Christopher Obbard <chris.obbard@collabora.com>
Signed-off-by: Jonas Karlman <jonas@kwiboo.se>
---
v2: New patch
---
 drivers/gpu/drm/bridge/synopsys/dw-hdmi.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

Neil Armstrong Sept. 9, 2024, 1:15 p.m. UTC | #1
On 08/09/2024 15:28, Jonas Karlman wrote:
> The scrambler feature can be left enabled when hotplugging from a sink
> and mode that require scrambling to a sink that does not support SCDC or
> scrambling.
> 
> Typically a blank screen or 'no signal' message can be observed after
> using a HDMI 2.0 4K@60Hz mode and then hotplugging to a sink that only
> support HDMI 1.4.
> 
> Fix this by disabling the scrambler feature when SCDC is not supported.
> 
> Fixes: 264fce6cc2c1 ("drm/bridge: dw-hdmi: Add SCDC and TMDS Scrambling support")
> Reported-by: Christopher Obbard <chris.obbard@collabora.com>
> Signed-off-by: Jonas Karlman <jonas@kwiboo.se>
> ---
> v2: New patch
> ---
>   drivers/gpu/drm/bridge/synopsys/dw-hdmi.c | 2 ++
>   1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c
> index 0031f3c54882..9e7f86a0bf5c 100644
> --- a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c
> +++ b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c
> @@ -2117,6 +2117,8 @@ static void hdmi_av_composer(struct dw_hdmi *hdmi,
>   				    HDMI_MC_SWRSTZ);
>   			drm_scdc_set_scrambling(hdmi->curr_conn, 0);
>   		}
> +	} else if (hdmi->version >= 0x200a) {
> +		hdmi_writeb(hdmi, 0, HDMI_FC_SCRAMBLER_CTRL);
>   	}
>   
>   	/* Set up horizontal active pixel width */

Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
diff mbox series

Patch

diff --git a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c
index 0031f3c54882..9e7f86a0bf5c 100644
--- a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c
+++ b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c
@@ -2117,6 +2117,8 @@  static void hdmi_av_composer(struct dw_hdmi *hdmi,
 				    HDMI_MC_SWRSTZ);
 			drm_scdc_set_scrambling(hdmi->curr_conn, 0);
 		}
+	} else if (hdmi->version >= 0x200a) {
+		hdmi_writeb(hdmi, 0, HDMI_FC_SCRAMBLER_CTRL);
 	}
 
 	/* Set up horizontal active pixel width */