Commit ce94bef9 authored by Chris Wilson's avatar Chris Wilson

drm/i915: Signal fence completion from i915_request_wait

With the upcoming change to automanaged i915_active, the intent is that
whenever we wait on the set of active fences, they are signaled and
collected.  The requirement is that all successful returns from
i915_request_wait() signal the fence, so fixup the one remaining path
where we may return before the interrupt has been run.
Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: default avatarTvrtko Ursulin <tvrtko.ursulin@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190619112341.9082-3-chris@chris-wilson.co.uk
parent 1ee008f2
...@@ -1447,8 +1447,10 @@ long i915_request_wait(struct i915_request *rq, ...@@ -1447,8 +1447,10 @@ long i915_request_wait(struct i915_request *rq,
for (;;) { for (;;) {
set_current_state(state); set_current_state(state);
if (i915_request_completed(rq)) if (i915_request_completed(rq)) {
dma_fence_signal(&rq->fence);
break; break;
}
if (signal_pending_state(state, current)) { if (signal_pending_state(state, current)) {
timeout = -ERESTARTSYS; timeout = -ERESTARTSYS;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment