public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
* [PATCH] drm/i915/vlv: honor i915_enable_rc6 boot param on VLV
@ 2013-09-19 16:33 Jesse Barnes
  2013-09-20  7:42 ` Daniel Vetter
  0 siblings, 1 reply; 2+ messages in thread
From: Jesse Barnes @ 2013-09-19 16:33 UTC (permalink / raw)
  To: intel-gfx

Disabling it isn't really an option on these platforms, but having it
available for power comparisons is useful.

Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
---
 drivers/gpu/drm/i915/intel_pm.c |    7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/intel_pm.c
index 0c115cc..c7764f8 100644
--- a/drivers/gpu/drm/i915/intel_pm.c
+++ b/drivers/gpu/drm/i915/intel_pm.c
@@ -3773,7 +3773,7 @@ static void valleyview_enable_rps(struct drm_device *dev)
 {
 	struct drm_i915_private *dev_priv = dev->dev_private;
 	struct intel_ring_buffer *ring;
-	u32 gtfifodbg, val;
+	u32 gtfifodbg, val, rc6_mode = 0;
 	int i;
 
 	WARN_ON(!mutex_is_locked(&dev_priv->rps.hw_lock));
@@ -3813,8 +3813,9 @@ static void valleyview_enable_rps(struct drm_device *dev)
 
 	/* allows RC6 residency counter to work */
 	I915_WRITE(0x138104, _MASKED_BIT_ENABLE(0x3));
-	I915_WRITE(GEN6_RC_CONTROL,
-		   GEN7_RC_CTL_TO_MODE);
+	if (intel_enable_rc6(dev) & INTEL_RC6_ENABLE)
+		rc6_mode = GEN7_RC_CTL_TO_MODE;
+	I915_WRITE(GEN6_RC_CONTROL, rc6_mode);
 
 	val = vlv_punit_read(dev_priv, PUNIT_REG_GPU_FREQ_STS);
 	switch ((val >> 6) & 3) {
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] drm/i915/vlv: honor i915_enable_rc6 boot param on VLV
  2013-09-19 16:33 [PATCH] drm/i915/vlv: honor i915_enable_rc6 boot param on VLV Jesse Barnes
@ 2013-09-20  7:42 ` Daniel Vetter
  0 siblings, 0 replies; 2+ messages in thread
From: Daniel Vetter @ 2013-09-20  7:42 UTC (permalink / raw)
  To: Jesse Barnes; +Cc: intel-gfx

On Thu, Sep 19, 2013 at 09:33:13AM -0700, Jesse Barnes wrote:
> Disabling it isn't really an option on these platforms, but having it
> available for power comparisons is useful.
> 
> Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>

Queued for -next, thanks for the patch.
-Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2013-09-20  7:42 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-09-19 16:33 [PATCH] drm/i915/vlv: honor i915_enable_rc6 boot param on VLV Jesse Barnes
2013-09-20  7:42 ` Daniel Vetter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox