[Intel-gfx] [PATCH 1/3] drm/i915: Refactor execlists default context pinning

Chris Wilson chris at chris-wilson.co.uk
Fri Apr 15 12:16:30 UTC 2016


On Fri, Apr 15, 2016 at 12:54:33PM +0100, Tvrtko Ursulin wrote:
> From: Chris Wilson <chris at chris-wilson.co.uk>
> 
> Refactor pinning and unpinning of contexts, such that the default
> context for an engine is pinned during initialisation and unpinned
> during teardown (pinning of the context handles the reference counting).
> Thus we can eliminate the special case handling of the default context
> that was required to mask that it was not being pinned normally.
> 
> v2:
>   * Rebase on nightly;
>   * put back pin in execlists_context_queue. (Tvrtko Ursulin)

No, we don't want to pin in execlists_context_queue!

We pin to acquire the request and then want to keep that pin for as long
as possible. For execlists, this means only dropping it when the
hardware is finished (which will be in the following request's
retirement).

Since we can handle an error during queue, the pin has to be upfront.
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre


More information about the Intel-gfx mailing list