]> www.infradead.org Git - users/jedix/linux-maple.git/commit
drm/amd/display: fix link_set_dpms_off multi-display MST corner case
authorGeorge Shen <george.shen@amd.com>
Thu, 24 Apr 2025 14:02:59 +0000 (10:02 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 13 May 2025 13:30:28 +0000 (09:30 -0400)
commit1561782686ccc36af844d55d31b44c938dd412dc
tree7d4213e4778573120f95be5f1f1d4027e9cf728a
parent53761b7ecd83e6fbb9f2206f8c980a6aa308c844
drm/amd/display: fix link_set_dpms_off multi-display MST corner case

[Why & How]
When MST config is unplugged/replugged too quickly, it can potentially
result in a scenario where previous DC state has not been reset before
the HPD link detection sequence begins. In this case, driver will
disable the streams/link prior to re-enabling the link for link
training.

There is a bug in the current logic that does not account for the fact
that current_state can be released and cleared prior to swapping to a
new state (resulting in the pipe_ctx stream pointers to be cleared) in
between disabling streams.

To resolve this, cache the original streams prior to committing any
stream updates.

Reviewed-by: Wenjing Liu <wenjing.liu@amd.com>
Signed-off-by: George Shen <george.shen@amd.com>
Signed-off-by: Ray Wu <ray.wu@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/link/link_dpms.c