All of lore.kernel.org
 help / color / mirror / Atom feed
From: Adam Jackson <ajax@redhat.com>
To: dri-devel@lists.freedesktop.org
Subject: [PATCH 3/5] drm/i915/dp: Probe branch/sink OUIs
Date: Mon, 14 May 2012 16:05:47 -0400	[thread overview]
Message-ID: <1337025949-2355-4-git-send-email-ajax@redhat.com> (raw)
In-Reply-To: <1337025949-2355-1-git-send-email-ajax@redhat.com>

Signed-off-by: Adam Jackson <ajax@redhat.com>
---
 drivers/gpu/drm/i915/intel_dp.c |   19 +++++++++++++++++++
 1 files changed, 19 insertions(+), 0 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
index 4b63791..cc8e1ef 100644
--- a/drivers/gpu/drm/i915/intel_dp.c
+++ b/drivers/gpu/drm/i915/intel_dp.c
@@ -1954,6 +1954,23 @@ intel_dp_get_dpcd(struct intel_dp *intel_dp)
 	return false;
 }
 
+static void
+intel_dp_probe_oui(struct intel_dp *intel_dp)
+{
+	u8 buf[3];
+
+	if (!(intel_dp->dpcd[DP_DOWN_STREAM_PORT_COUNT] & DP_OUI_SUPPORT))
+		return;
+
+	if (intel_dp_aux_native_read_retry(intel_dp, DP_SINK_OUI, buf, 3))
+		DRM_DEBUG_KMS("Sink OUI: %02hx%02hx%02hx\n",
+			      buf[0], buf[1], buf[2]);
+
+	if (intel_dp_aux_native_read_retry(intel_dp, DP_BRANCH_OUI, buf, 3))
+		DRM_DEBUG_KMS("Branch OUI: %02hx%02hx%02hx\n",
+			      buf[0], buf[1], buf[2]);
+}
+
 static bool
 intel_dp_get_sink_irq(struct intel_dp *intel_dp, u8 *sink_irq_vector)
 {
@@ -2137,6 +2154,8 @@ intel_dp_detect(struct drm_connector *connector, bool force)
 	if (status != connector_status_connected)
 		return status;
 
+	intel_dp_probe_oui(intel_dp);
+
 	if (intel_dp->force_audio != HDMI_AUDIO_AUTO) {
 		intel_dp->has_audio = (intel_dp->force_audio == HDMI_AUDIO_ON);
 	} else {
-- 
1.7.7.6

  parent reply	other threads:[~2012-05-14 20:05 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-14 20:05 [PATCH 0/5] Initial DisplayPort OUI probing Adam Jackson
2012-05-14 20:05 ` [PATCH 1/5] drm/dp: Add DPCD OUI register defines Adam Jackson
2012-05-14 20:05 ` [PATCH 2/5] drm/dp: Add DPCD defines for register 0x007 Adam Jackson
2012-05-14 20:05 ` Adam Jackson [this message]
2012-05-14 20:05 ` [PATCH 4/5] drm/radeon/dp: Probe branch/sink OUIs Adam Jackson
2012-05-14 20:05 ` [PATCH 5/5] drm/nouveau/dp: " Adam Jackson
2012-05-21 17:41 ` [PATCH 0/5] Initial DisplayPort OUI probing Adam Jackson
2012-05-21 18:32   ` Jerome Glisse
2012-05-21 18:47   ` Daniel Vetter
2012-05-21 19:27     ` Alex Deucher
2012-05-21 20:11       ` Adam Jackson
2012-05-21 20:35         ` Alex Deucher
2012-05-21 21:09           ` Adam Jackson
2012-05-21 21:48             ` Alex Deucher
2012-05-22  9:27 ` Dave Airlie

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=1337025949-2355-4-git-send-email-ajax@redhat.com \
    --to=ajax@redhat.com \
    --cc=dri-devel@lists.freedesktop.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.