public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
* [PATCH 1/2] drm/i915: use power well count instead of reading hw state when checking status
@ 2014-05-28 16:50 Jesse Barnes
  2014-05-28 16:50 ` [PATCH 2/2] drm/i915: rename is_enabled to hw_state Jesse Barnes
  2014-05-28 18:09 ` [PATCH 1/2] drm/i915: use power well count instead of reading hw state when checking status Imre Deak
  0 siblings, 2 replies; 11+ messages in thread
From: Jesse Barnes @ 2014-05-28 16:50 UTC (permalink / raw)
  To: intel-gfx

This saves many ms per call on my BYT by eliminating Punit communication
from the hw readout paths.

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

diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/intel_pm.c
index 452518f..09a3677 100644
--- a/drivers/gpu/drm/i915/intel_pm.c
+++ b/drivers/gpu/drm/i915/intel_pm.c
@@ -5572,13 +5572,11 @@ bool intel_display_power_enabled(struct drm_i915_private *dev_priv,
 
 	mutex_lock(&power_domains->lock);
 	for_each_power_well_rev(i, power_well, BIT(domain), power_domains) {
-		if (power_well->always_on)
+		if (power_well->always_on || power_well->count)
 			continue;
 
-		if (!power_well->ops->is_enabled(dev_priv, power_well)) {
-			is_enabled = false;
-			break;
-		}
+		is_enabled = false;
+		break;
 	}
 	mutex_unlock(&power_domains->lock);
 
-- 
1.8.4.2

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

end of thread, other threads:[~2014-06-19 11:45 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-05-28 16:50 [PATCH 1/2] drm/i915: use power well count instead of reading hw state when checking status Jesse Barnes
2014-05-28 16:50 ` [PATCH 2/2] drm/i915: rename is_enabled to hw_state Jesse Barnes
2014-05-28 18:09 ` [PATCH 1/2] drm/i915: use power well count instead of reading hw state when checking status Imre Deak
2014-05-28 18:17   ` Jesse Barnes
2014-06-05 17:31     ` [PATCH] drm/i915: cache hw power well enabled state Imre Deak
2014-06-05 17:35       ` Jesse Barnes
2014-06-05 17:44         ` Imre Deak
2014-06-06 17:19       ` Daniel Vetter
2014-06-06 17:37         ` Imre Deak
2014-06-06 18:05           ` Daniel Vetter
2014-06-19 11:45           ` Daniel Vetter

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