[Intel-gfx] [PATCH 03/11] drm/i915: return ctx->global_id from intel_execlists_ctx_id()

Dave Gordon david.s.gordon at intel.com
Tue Feb 16 09:34:29 UTC 2016

On 16/02/16 05:27, sourab.gupta at intel.com wrote:
> From: Robert Bragg <robert at sixbynine.org>
> The newly added intel_context::global_id is suitable (a globally unique
> 20 bit ID) for giving to the hardware as a unique context identifier.
> Compared to using the pinned address of a logical ring context these IDs
> are constant for the lifetime of a context whereas a context could be
> repinned at different addresses during its lifetime.
> Having a stable ID is useful when we need to buffer information
> associated with a context based on this ID so the association can't be
> lost. For example the OA unit writes out counter reports to a circular
> buffer tagged with this ID and we want to be able to accurately filter
> reports for a specific context, ideally without the added complexity of
> tracking context re-pinning while the OA buffer may contain reports with
> older IDs.

Unfortunately, I suspect that the GuC firmware has conflated the context 
ID (which ought to be a purely software-defined tag) with the (hardware) 
GTT page address of the LRC. So this will probably break GuC submission.

But it looks like a good idea otherwise; maybe we can get the GuC 
firmware updated so it doesn't make this assumption ...


More information about the Intel-gfx mailing list