From 9eab59c42b2662075a3eab13fe7aebf23e0c8234 Mon Sep 17 00:00:00 2001 From: Liav A Date: Sat, 4 Jun 2022 03:05:36 +0300 Subject: [PATCH] Kernel/Graphics: Return ENODEV if there's no valid EDID to return ENODEV better represents the fact that there might be no display device (e.g. a monitor) connected to the connector, therefore we should return this error. Another reason to not use ENOTIMPL is that it's a requirement for all DisplayConnectors to put a valid EDID in place even for a hardware we don't currently support mode-setting in runtime. --- Kernel/Graphics/DisplayConnector.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Kernel/Graphics/DisplayConnector.cpp b/Kernel/Graphics/DisplayConnector.cpp index b3516d7fe4..8e96853e17 100644 --- a/Kernel/Graphics/DisplayConnector.cpp +++ b/Kernel/Graphics/DisplayConnector.cpp @@ -268,7 +268,7 @@ DisplayConnector::ModeSetting DisplayConnector::current_mode_setting() const ErrorOr DisplayConnector::get_edid() const { if (!m_edid_valid) - return Error::from_errno(ENOTIMPL); + return Error::from_errno(ENODEV); return ByteBuffer::copy(m_edid_bytes, sizeof(m_edid_bytes)); }