public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Zhenyu Wang <zhenyuw@linux.intel.com>
To: intel-gfx@lists.freedesktop.org
Subject: [PATCH 2/4] drm/i915: save/restore DSPARB only for chips before gen4 but not for G33
Date: Wed, 23 Mar 2011 10:21:07 +0800	[thread overview]
Message-ID: <1300846869-28245-3-git-send-email-zhenyuw@linux.intel.com> (raw)
In-Reply-To: <1300846869-28245-1-git-send-email-zhenyuw@linux.intel.com>

DSPARB is reserved on G33 and not available on Gen6.

Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
---
 drivers/gpu/drm/i915/i915_suspend.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/i915/i915_suspend.c b/drivers/gpu/drm/i915/i915_suspend.c
index 0521ecf..8d165c4 100644
--- a/drivers/gpu/drm/i915/i915_suspend.c
+++ b/drivers/gpu/drm/i915/i915_suspend.c
@@ -603,7 +603,8 @@ void i915_save_display(struct drm_device *dev)
 	struct drm_i915_private *dev_priv = dev->dev_private;
 
 	/* Display arbitration control */
-	dev_priv->saveDSPARB = I915_READ(DSPARB);
+	if (dev_priv->info->gen < 4 && !IS_G33(dev))
+		dev_priv->saveDSPARB = I915_READ(DSPARB);
 
 	/* This is only meaningful in non-KMS mode */
 	/* Don't save them in KMS mode */
@@ -695,7 +696,8 @@ void i915_restore_display(struct drm_device *dev)
 	struct drm_i915_private *dev_priv = dev->dev_private;
 
 	/* Display arbitration */
-	I915_WRITE(DSPARB, dev_priv->saveDSPARB);
+	if (dev_priv->info->gen < 4 && !IS_G33(dev))
+		I915_WRITE(DSPARB, dev_priv->saveDSPARB);
 
 	/* Display port ratios (must be done before clock is set) */
 	if (SUPPORTS_INTEGRATED_DP(dev)) {
-- 
1.7.4.1

  parent reply	other threads:[~2011-03-23  2:21 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-23  2:21 [PATCH 0/4 rev2] Sandybridge suspend/resume fixes Zhenyu Wang
2011-03-23  2:21 ` [PATCH 1/4] drm/i915: clock gating fix for gen5 and gen6 Zhenyu Wang
2011-03-23  2:21 ` Zhenyu Wang [this message]
2011-03-23  3:03   ` [PATCH 2/4] drm/i915: save/restore DSPARB only for chips before gen4 but not for G33 Keith Packard
2011-03-23  4:20     ` Zhenyu Wang
2011-03-23  2:21 ` [PATCH 3/4] drm/i915: save/restore MI_ARB_STATE only before gen6 Zhenyu Wang
2011-03-23  2:21 ` [PATCH 4/4] drm/i915: move sandybridge RC6 enable in resume after ring initialization Zhenyu Wang
2011-03-23  6:22 ` [PATCH 0/4 rev2] Sandybridge suspend/resume fixes Fu Michael

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=1300846869-28245-3-git-send-email-zhenyuw@linux.intel.com \
    --to=zhenyuw@linux.intel.com \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox