Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Jesse Barnes <jbarnes@virtuousgeek.org>
To: intel-gfx@lists.freedesktop.org
Subject: [PATCH] drm/i915: disable rc6 on Cantiga and Crestline
Date: Fri, 24 Dec 2010 20:29:34 -0800	[thread overview]
Message-ID: <1293251374-2565-1-git-send-email-jbarnes@virtuousgeek.org> (raw)

The Ironlake code won't work on these old chips, so disable it to avoid
hanging older systems.

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

diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index 3f73690..3a488ef 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -6702,12 +6702,7 @@ void intel_modeset_init(struct drm_device *dev)
 	if (IS_IRONLAKE_M(dev)) {
 		ironlake_enable_drps(dev);
 		intel_init_emon(dev);
-	}
-
-	if (IS_GEN6(dev))
-		gen6_enable_rps(dev_priv);
 
-	if ((IS_GEN4(dev) || IS_GEN5(dev)) && IS_MOBILE(dev)) {
 		dev_priv->renderctx = intel_alloc_context_page(dev);
 		if (!dev_priv->renderctx)
 			goto skip_rc6;
@@ -6720,6 +6715,9 @@ void intel_modeset_init(struct drm_device *dev)
 		ironlake_enable_rc6(dev);
 	}
 
+	if (IS_GEN6(dev))
+		gen6_enable_rps(dev_priv);
+
 skip_rc6:
 	INIT_WORK(&dev_priv->idle_work, intel_idle_update);
 	setup_timer(&dev_priv->idle_timer, intel_gpu_idle_timer,
@@ -6752,14 +6750,13 @@ void intel_modeset_cleanup(struct drm_device *dev)
 	if (dev_priv->display.disable_fbc)
 		dev_priv->display.disable_fbc(dev);
 
-	if (IS_IRONLAKE_M(dev))
+	if (IS_IRONLAKE_M(dev)) {
 		ironlake_disable_drps(dev);
+		ironlake_disable_rc6(dev);
+	}
 	if (IS_GEN6(dev))
 		gen6_disable_rps(dev);
 
-	if ((IS_GEN4(dev) || IS_GEN5(dev)) && IS_MOBILE(dev))
-		ironlake_disable_rc6(dev);
-
 	mutex_unlock(&dev->struct_mutex);
 
 	/* Disable the irq before mode object teardown, for the irq might
-- 
1.7.2.3

             reply	other threads:[~2010-12-25  4:29 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-25  4:29 Jesse Barnes [this message]
2010-12-25 12:37 ` [PATCH] drm/i915: disable rc6 on Cantiga and Crestline Chris Wilson
2010-12-25 20:35   ` Jesse Barnes
2010-12-27 19:29   ` 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=1293251374-2565-1-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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox