RE: [PATCH] drm/amd/display: Increase the HDMI HPD disconnect filter time
From: Zuo, Jerry
Date: Thu Oct 29 2026 - 14:03:05 EST
AMD General
> -----Original Message-----
> From: dri-devel <dri-devel-bounces@xxxxxxxxxxxxxxxxxxxxx> On Behalf Of
> 2564278112@xxxxxx
> Sent: Thursday, October 8, 2026 03:32
> To: Wentland, Harry <Harry.Wentland@xxxxxxx>; Li, Sun peng (Leo)
> <Sunpeng.Li@xxxxxxx>; Rodrigo Siqueira <siqueira@xxxxxxxxxx>; Deucher,
> Alexander <Alexander.Deucher@xxxxxxx>; Koenig, Christian
> <Christian.Koenig@xxxxxxx>; David Airlie <airlied@xxxxxxxxx>; Simona
> Vetter <simona@xxxxxxxx>; amd-gfx@xxxxxxxxxxxxxxxxxxxxx
> Cc: Laktyushkin, Dmytro <Dmytro.Laktyushkin@xxxxxxx>; Li, Roman
> <Roman.Li@xxxxxxx>; Liu, Wenjing <Wenjing.Liu@xxxxxxx>; Chung,
> ChiaHsuan (Tom) <ChiaHsuan.Chung@xxxxxxx>; Varone, Dillon
> <Dillon.Varone@xxxxxxx>; Hung, Alex <Alex.Hung@xxxxxxx>; Lu Yao
> <yaolu@xxxxxxxxxx>; dri-devel@xxxxxxxxxxxxxxxxxxxxx; linux-
> kernel@xxxxxxxxxxxxxxx; Wang Jiang <jiangwang@xxxxxxxxxx>
> Subject: [PATCH] drm/amd/display: Increase the HDMI HPD disconnect filter
> time
>
> From: Wang Jiang <jiangwang@xxxxxxxxxx>
>
> The HPD filter programmed for the DVI/HDMI link types uses 100ms for a
> disconnect, which is shorter than the HPD low period that some sinks generate
> while they reconfigure, for example when the video mode changes or when
> the audio infoframe is updated. Such a sink is then reported as unplugged and
> plugged back in, so the connector is torn down and re-probed for nothing.
>
> Raise the disconnect filter to 800ms for the DVI/HDMI link types, including
> HDMI FRL. The delay is written to DC_HPD_TOGGLE_FILT_CNTL in 10ms units
> inside an 8-bit field, so 800ms is encoded as 80, and the filter runs in
> hardware, so there is no CPU cost. The connect filter is left at 500ms. A
> genuine unplug keeps HPD low, so the only cost is that the event is reported up
> to 800ms later.
>
> The DP branch above already tunes its filter values empirically to hide a
> bouncing HPD, and link_factory.c notes that a badly programmed GPIO makes
> HPD not "rise or drain fast enough, leading to bounces".
>
> Signed-off-by: Wang Jiang <jiangwang@xxxxxxxxxx>
> ---
> drivers/gpu/drm/amd/display/dc/link/protocols/link_hpd.c | 6 +++++-
> 1 file changed, 5 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/amd/display/dc/link/protocols/link_hpd.c
> b/drivers/gpu/drm/amd/display/dc/link/protocols/link_hpd.c
> index cfb5ef0523a7..2b38ddaaaa4b 100644
> --- a/drivers/gpu/drm/amd/display/dc/link/protocols/link_hpd.c
> +++ b/drivers/gpu/drm/amd/display/dc/link/protocols/link_hpd.c
> @@ -82,8 +82,12 @@ bool program_hpd_filter(const struct dc_link *link)
> case SIGNAL_TYPE_HDMI_TYPE_A:
> case SIGNAL_TYPE_HDMI_FRL:
> /* Program hpd filter */
> + /* Some HDMI/DVI sinks drive HPD low for a few hundred ms
> while
> + * they reconfigure; 100ms is not enough to hide that bounce,
> + * which is then reported as a fake unplug/plug pair.
> + */
> delay_on_connect_in_ms = 500;
> - delay_on_disconnect_in_ms = 100;
> + delay_on_disconnect_in_ms = 800;
Raising the HDMI HPD disconnect filter to 800 ms makes the source ignore the spec‑defined ≥100ms HPD‑low pulse (HDMI 1.4 §8.5 / HDMI 2.1 §12.1.1) used to signal E‑EDID changes, eARC discovery, and HDCP, so a sink that updates its EDID is no longer detected as requesting an EDID re-read.
Jerry
> break;
> case SIGNAL_TYPE_DISPLAY_PORT:
> case SIGNAL_TYPE_DISPLAY_PORT_MST:
> --
> 2.25.1