[PATCH] drm/amd/display: If HPD fails probe EDID to decide if monitor is present

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Some monitors return that they're disconnected while powered off
but the EDID can still be accessed.  Before determining that a
link is not available, try to access the EDID.

Reported-and-suggested-by: dark_sylinc@xxxxxxxxxxxx
Link: https://gitlab.freedesktop.org/drm/amd/-/issues/461
Signed-off-by: Mario Limonciello <mario.limonciello@xxxxxxx>
---
Cc: Harry Wentland <Harry.Wentland@xxxxxxx>
---
 drivers/gpu/drm/amd/display/dc/link/link_detection.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/gpu/drm/amd/display/dc/link/link_detection.c b/drivers/gpu/drm/amd/display/dc/link/link_detection.c
index c9b6676eaf53..26a739128dd3 100644
--- a/drivers/gpu/drm/amd/display/dc/link/link_detection.c
+++ b/drivers/gpu/drm/amd/display/dc/link/link_detection.c
@@ -1233,6 +1233,8 @@ bool link_detect_connection_type(struct dc_link *link, enum dc_connection_type *
 	if (is_hpd_high) {
 		*type = dc_connection_single;
 		/* TODO: need to do the actual detection */
+	} else if (dm_helpers_read_local_edid(link->ctx, link, link->local_sink) == EDID_OK) {
+		*type = dc_connection_single;
 	} else {
 		*type = dc_connection_none;
 		if (link->connector_signal == SIGNAL_TYPE_EDP) {
-- 
2.34.1




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux