From: Erick Karanja <karanja99erick@gmail.com>
To: andrzej.hajda@intel.com, neil.armstrong@linaro.org,
rfoss@kernel.org, maarten.lankhorst@linux.intel.com,
mripard@kernel.org, tzimmermann@suse.de, airlied@gmail.com,
simona@ffwll.ch
Cc: laurent.pinchart@ideasonboard.com, jonas@kwiboo.se,
jernej.skrabec@gmail.com, dri-devel@lists.freedesktop.org,
linux-kernel@vger.kernel.org,
Erick Karanja <karanja99erick@gmail.com>
Subject: [PATCH v2] drm/bridge: dw-hdmi: Replace calls to deprecated HDMI/audio detection functions
Date: Tue, 20 Jan 2026 11:27:31 +0300 [thread overview]
Message-ID: <20260120082731.15798-1-karanja99erick@gmail.com> (raw)
Replace calls to the deprecated drm_detect_hdmi_monitor() and
drm_detect_monitor_audio() functions. Calling drm_edid_connector_update()
updates connector->display_info.is_hdmi and connector->display_info.has_audio.
The driver should read these fields from connector->display_info instead of
calling the deprecated functions directly.
Signed-off-by: Erick Karanja <karanja99erick@gmail.com>
---
changes in v2:
- Remove unnecessary call to drm_edid_raw()
drivers/gpu/drm/bridge/synopsys/dw-hdmi.c | 17 +++--------------
1 file changed, 3 insertions(+), 14 deletions(-)
diff --git a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c
index 3b77e73ac0ea..ddc4ae40d94e 100644
--- a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c
+++ b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c
@@ -2472,7 +2472,6 @@ static const struct drm_edid *dw_hdmi_edid_read(struct dw_hdmi *hdmi,
struct drm_connector *connector)
{
const struct drm_edid *drm_edid;
- const struct edid *edid;
if (!hdmi->ddc)
return NULL;
@@ -2482,19 +2481,9 @@ static const struct drm_edid *dw_hdmi_edid_read(struct dw_hdmi *hdmi,
dev_dbg(hdmi->dev, "failed to get edid\n");
return NULL;
}
-
- /*
- * FIXME: This should use connector->display_info.is_hdmi and
- * connector->display_info.has_audio from a path that has read the EDID
- * and called drm_edid_connector_update().
- */
- edid = drm_edid_raw(drm_edid);
-
- dev_dbg(hdmi->dev, "got edid: width[%d] x height[%d]\n",
- edid->width_cm, edid->height_cm);
-
- hdmi->sink_is_hdmi = drm_detect_hdmi_monitor(edid);
- hdmi->sink_has_audio = drm_detect_monitor_audio(edid);
+ drm_edid_connector_update(connector, drm_edid);
+ hdmi->sink_is_hdmi = connector->display_info.is_hdmi;
+ hdmi->sink_has_audio = connector->display_info.has_audio;
return drm_edid;
}
--
2.51.0
next reply other threads:[~2026-01-20 8:27 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-20 8:27 Erick Karanja [this message]
2026-02-26 12:06 Erick Karanja
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260120082731.15798-1-karanja99erick@gmail.com \
--to=karanja99erick@gmail.com \
--cc=airlied@gmail.com \
--cc=andrzej.hajda@intel.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=jernej.skrabec@gmail.com \
--cc=jonas@kwiboo.se \
--cc=laurent.pinchart@ideasonboard.com \
--cc=linux-kernel@vger.kernel.org \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mripard@kernel.org \
--cc=neil.armstrong@linaro.org \
--cc=rfoss@kernel.org \
--cc=simona@ffwll.ch \
--cc=tzimmermann@suse.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®