drm/i915/guc: Make wq_lock irq-safe
authorChris Wilson <chris@chris-wilson.co.uk>
Tue, 28 Feb 2017 11:28:02 +0000 (11:28 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Tue, 28 Feb 2017 14:56:36 +0000 (14:56 +0000)
commit349ab9192cc32e578ce981936c6ab99ae3a96165
treeef6c8ae096cce487da9c0ad9195d84f1e0996215
parent1e08a260b178a6cb5547a28153f88661970474e5
drm/i915/guc: Make wq_lock irq-safe

Following the use of dma_fence_signal() from within our interrupt
handler, we need to make guc->wq_lock also irq-safe. This was done
previously as part of the guc scheduler patch (which also started
mixing our fences with the interrupt handler), but is now required to
fix the current guc submission backend.

v4: Document that __i915_guc_submit is always under an irq disabled
section
v5: Move wq_rsvd adjustment to its own function

Fixes: 67b807a89230 ("drm/i915: Delay disabling the user interrupt for breadcrumbs")
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
Reviewed-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/20170228112803.11646-2-chris@chris-wilson.co.uk
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
drivers/gpu/drm/i915/i915_guc_submission.c