All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jesse Barnes <jbarnes@virtuousgeek.org>
To: intel-gfx@lists.freedesktop.org
Subject: [PATCH 3/7] drm/i915: treat Ivy Bridge watermarks like Sandy Bridge
Date: Tue, 26 Apr 2011 16:51:04 -0700	[thread overview]
Message-ID: <1303861868-8805-3-git-send-email-jbarnes@virtuousgeek.org> (raw)
In-Reply-To: <1303861868-8805-1-git-send-email-jbarnes@virtuousgeek.org>

Not fully tested.

Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
---
 drivers/gpu/drm/i915/intel_display.c |    9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index 866abe5..908c4d9 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -7229,7 +7229,7 @@ void intel_enable_clock_gating(struct drm_device *dev)
 				   _3D_CHICKEN2_WM_READ_PIPELINED);
 		}
 
-		if (IS_GEN6(dev)) {
+		if (IS_GEN6(dev) || IS_IVYBRIDGE(dev)) {
 			I915_WRITE(WM3_LP_ILK, 0);
 			I915_WRITE(WM2_LP_ILK, 0);
 			I915_WRITE(WM1_LP_ILK, 0);
@@ -7491,6 +7491,13 @@ static void intel_init_display(struct drm_device *dev)
 				dev_priv->display.train_fdi = ivb_fdi_link_train;
 			else
 				dev_priv->display.train_fdi = ivb_manual_fdi_link_train;
+			if (SNB_READ_WM0_LATENCY()) {
+				dev_priv->display.update_wm = sandybridge_update_wm;
+			} else {
+				DRM_DEBUG_KMS("Failed to read display plane latency. "
+					      "Disable CxSR\n");
+				dev_priv->display.update_wm = NULL;
+			}
 		} else
 			dev_priv->display.update_wm = NULL;
 	} else if (IS_PINEVIEW(dev)) {
-- 
1.7.4.1

  parent reply	other threads:[~2011-04-26 23:51 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-26 23:51 [PATCH 1/7] drm/i915: automatic FDI training support for Ivy Bridge Jesse Barnes
2011-04-26 23:51 ` [PATCH 2/7] drm/i915: manual FDI training " Jesse Barnes
2011-04-26 23:51 ` Jesse Barnes [this message]
2011-04-26 23:51 ` [PATCH 4/7] drm/i915: interrupt & vblank support " Jesse Barnes
2011-04-26 23:51 ` [PATCH 5/7] drm/i915: page flip " Jesse Barnes
2011-04-26 23:51 ` [PATCH 6/7] drm/i915: untested DP " Jesse Barnes
2011-04-26 23:51 ` [PATCH 7/7] drm/i915: ring " Jesse Barnes
2011-04-27  0:06 ` [PATCH 1/7] drm/i915: automatic FDI training " Jesse Barnes
2011-04-27  6:19   ` Chris Wilson
2011-04-27 20:52     ` Jesse Barnes

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=1303861868-8805-3-git-send-email-jbarnes@virtuousgeek.org \
    --to=jbarnes@virtuousgeek.org \
    --cc=intel-gfx@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.