[Intel-gfx] [PATCH 7/8] drm/i915: Grab execlist spinlock to avoid post-reset concurrency issues.

Chris Wilson chris at chris-wilson.co.uk
Fri Oct 9 00:45:40 PDT 2015

On Thu, Oct 08, 2015 at 07:31:39PM +0100, Tomas Elf wrote:
> Grab execlist lock when cleaning up execlist queues after GPU reset to avoid
> concurrency problems between the context event interrupt handler and the reset
> path immediately following a GPU reset.

Hmm, my tree just does:

static void i915_gem_reset_ring_cleanup(struct drm_i915_private *dev_priv,
                                        struct intel_engine_cs *ring)
         * Clear the execlists queue up before freeing the requests, as those
         * are the ones that keep the context and ringbuffer backing objects
         * pinned in place.
        if (i915.enable_execlists) {
                memset(&ring->execlist_port, 0, sizeof(ring->execlist_port));


Oh, that's right another unreviewed patch from several months ago.

For your patch, you should not take the spinlock unconditionally as it is
only initialised for execlists, and you can use the simpler form of irq
locking as above.

Chris Wilson, Intel Open Source Technology Centre

More information about the Intel-gfx mailing list