Commit f2253bd9 authored by Chris Wilson's avatar Chris Wilson

drm/i915/ringbuffer: EMIT_INVALIDATE after switch context

The recommend procedure was to switch contexts (and mm) then invalidate
the TLBs. Make it so.
Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: default avatarTvrtko Ursulin <tvrtko.ursulin@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20181207090213.14352-2-chris@chris-wilson.co.uk
parent 5f5800a7
...@@ -1827,12 +1827,12 @@ static int ring_request_alloc(struct i915_request *request) ...@@ -1827,12 +1827,12 @@ static int ring_request_alloc(struct i915_request *request)
*/ */
request->reserved_space += LEGACY_REQUEST_SIZE; request->reserved_space += LEGACY_REQUEST_SIZE;
/* Unconditionally invalidate GPU caches and TLBs. */ ret = switch_context(request);
ret = request->engine->emit_flush(request, EMIT_INVALIDATE);
if (ret) if (ret)
return ret; return ret;
ret = switch_context(request); /* Unconditionally invalidate GPU caches and TLBs. */
ret = request->engine->emit_flush(request, EMIT_INVALIDATE);
if (ret) if (ret)
return ret; return ret;
......
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