]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915/gem: Lazily acquire the device wakeref for freeing objects
authorChris Wilson <chris@chris-wilson.co.uk>
Sun, 3 May 2020 17:15:13 +0000 (18:15 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Mon, 4 May 2020 10:12:37 +0000 (11:12 +0100)
commitc2bbb667059f8e9633832c6831d8f3694ab23fa8
tree13ed227c1fc973df187e3f5b4d5889d850aa1a92
parentce5cbd1ca725bdb380195d204477ba1be1e0879b
drm/i915/gem: Lazily acquire the device wakeref for freeing objects

We only need the device wakeref on freeing the objects if we have to
unbind the object from the global GTT, or otherwise update device
information. If the objects are clean, we never need the wakeref, so
avoid taking until required.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Janusz Krzysztofik <janusz.krzysztofik@linux.intel.com>
Reviewed-by: Janusz Krzysztofik <janusz.krzysztofik@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200503171513.18704-1-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/gem/i915_gem_object.c