All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/i915: Warn there are any unfreed contexts when we shutdown
@ 2016-04-22 13:03 Chris Wilson
  2016-04-22 13:04 ` Daniel Vetter
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Chris Wilson @ 2016-04-22 13:03 UTC (permalink / raw)
  To: intel-gfx; +Cc: Mika Kuoppala

When tearing down the device, emit a warning if there are any contexts
remaining, as they all should be freed by this point.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Mika Kuoppala <mika.kuoppala@intel.com>
Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
---
 drivers/gpu/drm/i915/i915_gem_context.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/gpu/drm/i915/i915_gem_context.c b/drivers/gpu/drm/i915/i915_gem_context.c
index e5acc3916f75..82339b45cc9b 100644
--- a/drivers/gpu/drm/i915/i915_gem_context.c
+++ b/drivers/gpu/drm/i915/i915_gem_context.c
@@ -437,6 +437,8 @@ void i915_gem_context_fini(struct drm_device *dev)
 
 	i915_gem_context_unreference(dctx);
 	dev_priv->kernel_context = NULL;
+
+	WARN_ON(!list_empty(&dev_priv->context_list));
 }
 
 int i915_gem_context_enable(struct drm_i915_gem_request *req)
-- 
2.8.1

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

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

end of thread, other threads:[~2016-04-24  8:23 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-04-22 13:03 [PATCH] drm/i915: Warn there are any unfreed contexts when we shutdown Chris Wilson
2016-04-22 13:04 ` Daniel Vetter
2016-04-22 13:25 ` Joonas Lahtinen
2016-04-22 14:33 ` ✗ Fi.CI.BAT: failure for " Patchwork
2016-04-24  8:23 ` ✓ Fi.CI.BAT: success " Patchwork

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.