drm/i915/gt: Flush engine->retire on virtual engine cleanup
diff mbox series

Message ID 20191219204417.131219-1-chris@chris-wilson.co.uk
State New
Headers show
Series
  • drm/i915/gt: Flush engine->retire on virtual engine cleanup
Related show

Commit Message

Chris Wilson Dec. 19, 2019, 8:44 p.m. UTC
For commit dc93c9b69315 ("drm/i915/gt: Schedule request retirement when
signaler idles") we added the intel_engine_init_retire() to the virtual
engine, but since it does not use the common cleanup routine, we need to
also add the intel_engine_fini_retire() to flush the retirement worker
before freeing.

Fixes: dc93c9b69315 ("drm/i915/gt: Schedule request retirement when signaler idles")
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
---
 drivers/gpu/drm/i915/gt/intel_lrc.c | 2 ++
 1 file changed, 2 insertions(+)

Patch
diff mbox series

diff --git a/drivers/gpu/drm/i915/gt/intel_lrc.c b/drivers/gpu/drm/i915/gt/intel_lrc.c
index 56cf71d8bbda..3f6bbda4391e 100644
--- a/drivers/gpu/drm/i915/gt/intel_lrc.c
+++ b/drivers/gpu/drm/i915/gt/intel_lrc.c
@@ -4209,6 +4209,8 @@  static void virtual_context_destroy(struct kref *kref)
 		__execlists_context_fini(&ve->context);
 	intel_context_fini(&ve->context);
 
+	intel_engine_fini_retire(&ve->base);
+
 	kfree(ve->bonds);
 	kfree(ve);
 }