Commit 3265124a authored by Chris Wilson's avatar Chris Wilson
Browse files

drm/i915: Give more details for the active-when-parking warning for the engines

If the we think the engine is still active when we attempt to park it,
we want more details -- so dump the engine state.

References: https://bugs.freedesktop.org/show_bug.cgi?id=103479


Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20171027110617.31745-4-chris@chris-wilson.co.uk


Reviewed-by: default avatarMika Kuoppala <mika.kuoppala@linux.intel.com>
parent 68027387
Loading
Loading
Loading
Loading
+13 −7
Original line number Diff line number Diff line
@@ -1613,14 +1613,20 @@ void intel_engines_park(struct drm_i915_private *i915)
	struct intel_engine_cs *engine;
	enum intel_engine_id id;

	for_each_engine(engine, i915, id) {
		/*
		 * We are committed now to parking the engines, make sure there
	 * will be no more interrupts arriving later.
		 * will be no more interrupts arriving later and the engines
		 * are truly idle.
		 */
	if (!intel_engines_are_idle(dev_priv))
		DRM_ERROR("Timeout waiting for engines to idle\n");
		if (!intel_engine_is_idle(engine)) {
			struct drm_printer p = drm_debug_printer(__func__);

			DRM_ERROR("%s is not idle before parking\n",
				  engine->name);
			intel_engine_dump(engine, &p);
		}

	for_each_engine(engine, i915, id) {
		if (engine->park)
			engine->park(engine);