On 3/15/12 10:42 AM, Takashi Iwai wrote:
diff --git a/drivers/gpu/drm/i915/intel_display.c
b/drivers/gpu/drm/i915/intel_display.c
index f851db7..314af26 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -356,6 +356,23 @@ static const intel_limit_t
intel_limits_ironlake_display_port = {
.find_pll = intel_find_pll_ironlake_dp,
};
+static bool is_dual_link_lvds(struct drm_i915_private *dev_priv,
+ unsigned int reg)
+{
+ /* BIOS should set the proper LVDS register value at boot, but
+ * in reality, it doesn't set the value when the lid is closed;
+ * thus when a machine is booted with the lid closed, the LVDS
+ * reg value can't be trusted. So we need to check "the value
+ * to be set" in VBT at first.
+ */
+ if ((dev_priv->bios_lvds_val & LVDS_CLKB_POWER_MASK) ==
+ LVDS_CLKB_POWER_UP)
+ return true;
Would slightly prefer if this was more like:
if (dev_priv->bios_lvds_val)
return !!(dev_priv->bios_lvds_val & LVDS_CLKB_POWER_MASK);
Since that way it eliminates some useless register reads in the normal
case even for single-link. Not going to insist on it though.
Looks really good otherwise, thanks!
Reviewed-by: Adam Jackson <a...@redhat.com>
- ajax
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx