]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915: Change shrink ordering to use locking around unbinding.
authorMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
Thu, 16 Dec 2021 14:27:34 +0000 (15:27 +0100)
committerMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
Mon, 20 Dec 2021 15:26:19 +0000 (16:26 +0100)
commit0f3d0bbe1d83f246607c8ee4e2a2d8dcfa9c9013
tree2cc417a34cd6609f5901c50250018ae5c737b1e9
parentac3c0609e0bcd42722242a836c04dc7aaef3d68b
drm/i915: Change shrink ordering to use locking around unbinding.

Call drop_pages with the gem object lock held, instead of the other
way around. This will allow us to drop the vma bindings with the
gem object lock held.

We plan to require the object lock for unpinning in the future,
and this is an easy target.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Niranjana Vishwanathapura <niranjana.vishwanathapura@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20211216142749.1966107-3-maarten.lankhorst@linux.intel.com
drivers/gpu/drm/i915/gem/i915_gem_shrinker.c