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

drm/amd/display: Only update link settings after successful MST link train

[WHY]
Currently driver reduces verified link caps on DPIA devices if a link is
trained at a link rate below the max rate verified during link detection.
This blocks high bandwidth modes after setting a low bandwidth mode.

[HOW]
Only update link rate after a successful link train if link is MST.

Reviewed-by: Mustapha Ghaddar <Mustapha.Ghaddar@amd.com>
Acked-by: Alan Liu <HaoPing.Liu@amd.com>
Signed-off-by: Michael Strauss <michael.strauss@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>

authored by

Michael Strauss and committed by
Alex Deucher
ea192af5 1df6b9b0

+22 -2
+8
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c
··· 971 971 { 972 972 /* TODO: add periodic detection implementation */ 973 973 } 974 + 975 + void dm_helpers_dp_mst_update_branch_bandwidth( 976 + struct dc_context *ctx, 977 + struct dc_link *link) 978 + { 979 + // TODO 980 + } 981 +
+4
drivers/gpu/drm/amd/display/dc/core/dc_link.c
··· 4663 4663 link->preferred_link_setting.link_rate = LINK_RATE_UNKNOWN; 4664 4664 } 4665 4665 4666 + if (link->connector_signal == SIGNAL_TYPE_DISPLAY_PORT && 4667 + link->type == dc_connection_mst_branch) 4668 + dm_helpers_dp_mst_update_branch_bandwidth(dc->ctx, link); 4669 + 4666 4670 /* Retrain now, or wait until next stream update to apply */ 4667 4671 if (skip_immediate_retrain == false) 4668 4672 dc_link_set_preferred_link_settings(dc, &link->preferred_link_setting, link);
+5
drivers/gpu/drm/amd/display/dc/dm_helpers.h
··· 116 116 bool dm_helpers_dp_mst_stop_top_mgr( 117 117 struct dc_context *ctx, 118 118 struct dc_link *link); 119 + 120 + void dm_helpers_dp_mst_update_branch_bandwidth( 121 + struct dc_context *ctx, 122 + struct dc_link *link); 123 + 119 124 /** 120 125 * OS specific aux read callback. 121 126 */