From: Shobhit Kumar <shobhit.kumar@intel.com>
To: intel-gfx <intel-gfx@lists.freedesktop.org>
Cc: Daniel Vetter <daniel.vetter@intel.com>,
Jesse Barnes <jesse.barnes@intel.com>
Subject: [PATCH] drm/i915: Update bits to check in device class from VBT to detect eDP
Date: Thu, 5 Jun 2014 18:25:13 +0530 [thread overview]
Message-ID: <1401972913-1771-1-git-send-email-shobhit.kumar@intel.com> (raw)
The DEVICE_TYPE_eDP has been changed to 0x1806 in case of BYT which
can causes wrong detection failures for eDP. Reduce the number of bits
of interest in DEVICE_TYPE_eDP_BITS to just check most relevant and
conclusive ones and ensure they are set in device_class from VBT. This
will ensure that eDP detection works across platforms
Signed-off-by: Shobhit Kumar <shobhit.kumar@intel.com>
---
drivers/gpu/drm/i915/intel_bios.h | 10 +---------
drivers/gpu/drm/i915/intel_dp.c | 4 ++--
2 files changed, 3 insertions(+), 11 deletions(-)
diff --git a/drivers/gpu/drm/i915/intel_bios.h b/drivers/gpu/drm/i915/intel_bios.h
index b986677..30d02b7 100644
--- a/drivers/gpu/drm/i915/intel_bios.h
+++ b/drivers/gpu/drm/i915/intel_bios.h
@@ -710,16 +710,8 @@ int intel_parse_bios(struct drm_device *dev);
*/
#define DEVICE_TYPE_eDP_BITS \
(DEVICE_TYPE_INTERNAL_CONNECTOR | \
- DEVICE_TYPE_NOT_HDMI_OUTPUT | \
- DEVICE_TYPE_MIPI_OUTPUT | \
- DEVICE_TYPE_COMPOSITE_OUTPUT | \
- DEVICE_TYPE_DUAL_CHANNEL | \
- DEVICE_TYPE_LVDS_SINGALING | \
- DEVICE_TYPE_TMDS_DVI_SIGNALING | \
- DEVICE_TYPE_VIDEO_SIGNALING | \
DEVICE_TYPE_DISPLAYPORT_OUTPUT | \
- DEVICE_TYPE_DIGITAL_OUTPUT | \
- DEVICE_TYPE_ANALOG_OUTPUT)
+ DEVICE_TYPE_DIGITAL_OUTPUT)
/* define the DVO port for HDMI output type */
#define DVO_B 1
diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
index dad3780..68f7380 100644
--- a/drivers/gpu/drm/i915/intel_dp.c
+++ b/drivers/gpu/drm/i915/intel_dp.c
@@ -3842,8 +3842,8 @@ bool intel_dp_is_edp(struct drm_device *dev, enum port port)
p_child = dev_priv->vbt.child_dev + i;
if (p_child->common.dvo_port == port_mapping[port] &&
- (p_child->common.device_type & DEVICE_TYPE_eDP_BITS) ==
- (DEVICE_TYPE_eDP & DEVICE_TYPE_eDP_BITS))
+ ((p_child->common.device_type & DEVICE_TYPE_eDP_BITS) ==
+ DEVICE_TYPE_eDP_BITS))
return true;
}
return false;
--
1.9.1
next reply other threads:[~2014-06-05 12:55 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-05 12:55 Shobhit Kumar [this message]
2014-06-05 13:09 ` [PATCH] drm/i915: Update bits to check in device class from VBT to detect eDP Ville Syrjälä
2014-06-05 16:04 ` Jesse Barnes
2014-06-06 4:03 ` Kumar, Shobhit
2014-06-06 5:36 ` Kumar, Shobhit
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=1401972913-1771-1-git-send-email-shobhit.kumar@intel.com \
--to=shobhit.kumar@intel.com \
--cc=daniel.vetter@intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=jesse.barnes@intel.com \
/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