Skip to content

Commit 0bfcb56

Browse files
Zhikai Zhaialexdeucher
authored andcommitted
drm/amd/display: Modify the link training policy
[Why&How] Currently fallback to low link rate if the link training fails once on USB4. It may cause the bandwidth couldn't satisfy the requirement of streams. Modify the policy to do training retry in the previous few times, only do fallback at the last time. Reviewed-by: Meenakshikumar Somasundaram <meenakshikumar.somasundaram@amd.com> Signed-off-by: Zhikai Zhai <zhikai.zhai@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>
1 parent 46fbe1e commit 0bfcb56

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

drivers/gpu/drm/amd/display/dc/link/protocols/link_dp_training.c

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1729,6 +1729,15 @@ bool perform_link_training_with_retries(
17291729
break;
17301730
}
17311731

1732+
if (link->ep_type == DISPLAY_ENDPOINT_USB4_DPIA &&
1733+
stream->signal == SIGNAL_TYPE_DISPLAY_PORT_MST &&
1734+
!link->dc->config.enable_dpia_pre_training) {
1735+
if (j == (attempts - 1))
1736+
do_fallback = true;
1737+
else
1738+
do_fallback = false;
1739+
}
1740+
17321741
if (j == (attempts - 1)) {
17331742
DC_LOG_WARNING(
17341743
"%s: Link(%d) training attempt %u of %d failed @ rate(%d) x lane(%d) @ spread = %x : fail reason:(%d)\n",

0 commit comments

Comments
 (0)