]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915: Remove waiting & retiring from shrinker paths
authorChris Wilson <chris@chris-wilson.co.uk>
Fri, 21 Jun 2019 18:37:57 +0000 (19:37 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Fri, 21 Jun 2019 18:47:48 +0000 (19:47 +0100)
commitb46904a65be5c1aa72261a182fe04a558e484af5
tree2c849e4e2c45b3ad64a1144d76625d4356353b73
parente938089b2bdf1b79099e2b954b11882b823edafd
drm/i915: Remove waiting & retiring from shrinker paths

i915_gem_wait_for_idle() and i915_retire_requests() introduce a
dependency on the timeline->mutex. This is problematic as we want to
later perform allocations underneath i915_active.mutex, forming a link
between the shrinker, the timeline and active mutexes. Nip this cycle in
the bud by removing the acquisition of the timeline mutex (i.e.
retiring) from inside the shrinker.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190621183801.23252-1-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/gem/i915_gem_shrinker.c
drivers/gpu/drm/i915/gem/selftests/i915_gem_context.c
drivers/gpu/drm/i915/gt/intel_gt_types.h
drivers/gpu/drm/i915/gt/intel_timeline.c