[PATCH 3/4] drm/i915: Move parking-while-active warning to intel_engines_park()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



We will want to break this down to give detailed per-engine warnings as
to why we still think we are active as we attempt to park the engines.
For the first step, just move the warning verbatim from the idle-worker
to intel_engines_park().

Signed-off-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>
---
 drivers/gpu/drm/i915/i915_gem.c        | 7 -------
 drivers/gpu/drm/i915/intel_engine_cs.c | 7 +++++++
 2 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c
index c2506fb3a483..4d1296f27ca1 100644
--- a/drivers/gpu/drm/i915/i915_gem.c
+++ b/drivers/gpu/drm/i915/i915_gem.c
@@ -3350,13 +3350,6 @@ i915_gem_idle_work_handler(struct work_struct *work)
 	 */
 	synchronize_irq(dev_priv->drm.irq);
 
-	/*
-	 * We are committed now to parking the engines, make sure there
-	 * will be no more interrupts arriving later.
-	 */
-	if (!intel_engines_are_idle(dev_priv))
-		DRM_ERROR("Timeout waiting for engines to idle\n");
-
 	intel_engines_park(dev_priv);
 	i915_gem_timelines_mark_idle(dev_priv);
 
diff --git a/drivers/gpu/drm/i915/intel_engine_cs.c b/drivers/gpu/drm/i915/intel_engine_cs.c
index f31f2d6384c3..9767586e2289 100644
--- a/drivers/gpu/drm/i915/intel_engine_cs.c
+++ b/drivers/gpu/drm/i915/intel_engine_cs.c
@@ -1613,6 +1613,13 @@ void intel_engines_park(struct drm_i915_private *i915)
 	struct intel_engine_cs *engine;
 	enum intel_engine_id id;
 
+	/*
+	 * We are committed now to parking the engines, make sure there
+	 * will be no more interrupts arriving later.
+	 */
+	if (!intel_engines_are_idle(dev_priv))
+		DRM_ERROR("Timeout waiting for engines to idle\n");
+
 	for_each_engine(engine, i915, id) {
 		if (engine->park)
 			engine->park(engine);
-- 
2.15.0.rc2

_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux