Commit b0942618 authored by Jake Wang's avatar Jake Wang Committed by Alex Deucher

drm/amd/display: Bypass sink detect when there are no eDPs connected

[How & Why]
Check DC config to determine if there are any eDPs connected. If there
are no eDPs connected, bypass sink detect when querying eDP presence.
Tested-by: default avatarDaniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: default avatarJake Wang <haonan.wang2@amd.com>
Reviewed-by: default avatarNicholas Kazlauskas <Nicholas.Kazlauskas@amd.com>
Acked-by: default avatarSolomon Chiu <solomon.chiu@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 45150cd2
...@@ -1096,20 +1096,19 @@ static void detect_edp_presence(struct dc *dc) ...@@ -1096,20 +1096,19 @@ static void detect_edp_presence(struct dc *dc)
{ {
struct dc_link *edp_links[MAX_NUM_EDP]; struct dc_link *edp_links[MAX_NUM_EDP];
struct dc_link *edp_link = NULL; struct dc_link *edp_link = NULL;
enum dc_connection_type type;
int i; int i;
int edp_num; int edp_num;
bool edp_sink_present = true;
get_edp_links(dc, edp_links, &edp_num); get_edp_links(dc, edp_links, &edp_num);
if (!edp_num) if (!edp_num)
return; return;
if (dc->config.edp_not_connected) { for (i = 0; i < edp_num; i++) {
edp_sink_present = false; edp_link = edp_links[i];
} else { if (dc->config.edp_not_connected) {
enum dc_connection_type type; edp_link->edp_sink_present = false;
for (i = 0; i < edp_num; i++) { } else {
edp_link = edp_links[i];
dc_link_detect_sink(edp_link, &type); dc_link_detect_sink(edp_link, &type);
edp_link->edp_sink_present = (type != dc_connection_none); edp_link->edp_sink_present = (type != dc_connection_none);
} }
......
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