Commit 82db2e3c authored by Sivapiriyan Kumarasamy's avatar Sivapiriyan Kumarasamy Committed by Alex Deucher

drm/amd/display: fix bug with check for HPD Low in verify link cap

[Why]
There is a bug when determining if link training should be retried when
HPD is low in dp_verify_link_cap_with_retries.

[How]
Correctly, fail dp_verify_link_cap_with_retries without retry when
HPD is low.
Signed-off-by: default avatarSivapiriyan Kumarasamy <sivapiriyan.kumarasamy@amd.com>
Reviewed-by: default avatarWenjing Liu <Wenjing.Liu@amd.com>
Acked-by: default avatarAbdoulaye Berthe <Abdoulaye.Berthe@amd.com>
Acked-by: default avatarBhawanpreet Lakha <Bhawanpreet.Lakha@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 15caeabc
...@@ -1656,11 +1656,14 @@ bool dp_verify_link_cap_with_retries( ...@@ -1656,11 +1656,14 @@ bool dp_verify_link_cap_with_retries(
for (i = 0; i < attempts; i++) { for (i = 0; i < attempts; i++) {
int fail_count = 0; int fail_count = 0;
enum dc_connection_type type; enum dc_connection_type type = dc_connection_none;
memset(&link->verified_link_cap, 0, memset(&link->verified_link_cap, 0,
sizeof(struct dc_link_settings)); sizeof(struct dc_link_settings));
if (!dc_link_detect_sink(link, &type)) { if (!dc_link_detect_sink(link, &type) || type == dc_connection_none) {
link->verified_link_cap.lane_count = LANE_COUNT_ONE;
link->verified_link_cap.link_rate = LINK_RATE_LOW;
link->verified_link_cap.link_spread = LINK_SPREAD_DISABLED;
break; break;
} else if (dp_verify_link_cap(link, } else if (dp_verify_link_cap(link,
&link->reported_link_cap, &link->reported_link_cap,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment