diff --git a/drivers/gpu/drm/i915/gt/intel_lrc.c b/drivers/gpu/drm/i915/gt/intel_lrc.c index f8ad49006917ca56950d7b42ddb541b1deb67c80..faa9a2e4e40b97c08d187bc1de19e1f2db257f72 100644 --- a/drivers/gpu/drm/i915/gt/intel_lrc.c +++ b/drivers/gpu/drm/i915/gt/intel_lrc.c @@ -557,9 +557,6 @@ execlists_schedule_out(struct i915_request *rq) intel_engine_context_out(ce->inflight); execlists_context_status_change(rq, INTEL_CONTEXT_SCHEDULE_OUT); - ce->inflight = NULL; - intel_context_put(ce); - /* * If this is part of a virtual engine, its next request may * have been blocked waiting for access to the active context. @@ -569,8 +566,11 @@ execlists_schedule_out(struct i915_request *rq) * request before the tasklet runs and do not need to rebuild * each virtual tree and kick everyone again. */ + ce->inflight = NULL; if (rq->engine != ce->engine) kick_siblings(rq, ce); + + intel_context_put(ce); } i915_request_put(rq);