[Intel-gfx] [PATCH 13/24] drm/i915: Pin engine before pinning all objects, v5.

Thomas Hellström (Intel) thomas_os at shipmail.org
Wed Aug 12 19:01:03 UTC 2020


On 8/10/20 12:30 PM, Maarten Lankhorst wrote:
> We want to lock all gem objects, including the engine context objects,
> rework the throttling to ensure that we can do this. Now we only throttle
> once, but can take eb_pin_engine while acquiring objects. This means we
> will have to drop the lock to wait. If we don't have to throttle we can
> still take the fastpath, if not we will take the slowpath and wait for
> the throttle request while unlocked.
>
> The engine has to be pinned as first step, otherwise gpu relocations
> won't work.
>
> Changes since v1:
> - Only need to get a throttled request in the fastpath, no need for
>    a global flag any more.
> - Always free the waited request correctly.
> Changes since v2:
> - Use intel_engine_pm_get()/put() to keeep engine pool alive during
>    EDEADLK handling.
> Changes since v3:
> - Fix small rq leak.
> Changes since v4:
> - Use a single reloc_context, for intel_context_pin_ww().
>
> Signed-off-by: Maarten Lankhorst <maarten.lankhorst at linux.intel.com>

Reviewed-by: Thomas Hellström <thomas.hellstrom at intel.com>




More information about the Intel-gfx mailing list