Commit c0e31018 authored by Chris Wilson's avatar Chris Wilson

drm/i915: Skip barriers inside waits

Attaching to the i915_active barrier is a two stage process, and a flush
is only effective when the barrier is activation. Thus it is possible
for us to see a barrier, and attempt to flush, only for our flush to
have no effect. As such, before attempting to activate signaling on the
fence we need to double check it is a fence!

Fixes: d13a3177 ("drm/i915: Flush idle barriers when waiting")
Closes: https://gitlab.freedesktop.org/drm/intel/issues/1333Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: default avatarAndi Shyti <andi.shyti@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200227085723.1961649-1-chris@chris-wilson.co.uk
parent 69edc390
...@@ -453,6 +453,9 @@ static void enable_signaling(struct i915_active_fence *active) ...@@ -453,6 +453,9 @@ static void enable_signaling(struct i915_active_fence *active)
{ {
struct dma_fence *fence; struct dma_fence *fence;
if (unlikely(is_barrier(active)))
return;
fence = i915_active_fence_get(active); fence = i915_active_fence_get(active);
if (!fence) if (!fence)
return; return;
......
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