Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drm/amd/display: stop top_mgr when type change to non-MST during s3

[Why]
Driver keeps the invalid information cause report the
incorrect monitor which save in remote sink to OS

[How]
When connector type change from MST to non-MST,
stop the topology manager.

Signed-off-by: Lewis Huang <Lewis.Huang@amd.com>
Reviewed-by: Tony Cheng <Tony.Cheng@amd.com>
Acked-by: Qingqing Zhuo <qingqing.zhuo@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>

authored by

Lewis Huang and committed by
Alex Deucher
e748b59f 202ad02d

+8
+8
drivers/gpu/drm/amd/display/dc/core/dc_link.c
··· 854 854 struct dpcd_caps prev_dpcd_caps; 855 855 bool same_dpcd = true; 856 856 enum dc_connection_type new_connection_type = dc_connection_none; 857 + enum dc_connection_type pre_connection_type = dc_connection_none; 857 858 bool perform_dp_seamless_boot = false; 858 859 const uint32_t post_oui_delay = 30; // 30ms 859 860 ··· 890 889 891 890 link_disconnect_sink(link); 892 891 if (new_connection_type != dc_connection_none) { 892 + pre_connection_type = link->type; 893 893 link->type = new_connection_type; 894 894 link->link_state_valid = false; 895 895 ··· 962 960 /* Downstream unplug */ 963 961 dc_sink_release(prev_sink); 964 962 return true; 963 + } 964 + 965 + // link switch from MST to non-MST stop topology manager 966 + if (pre_connection_type == dc_connection_mst_branch && 967 + link->type != dc_connection_mst_branch) { 968 + dm_helpers_dp_mst_stop_top_mgr(link->ctx, link); 965 969 } 966 970 967 971 if (link->type == dc_connection_mst_branch) {