]> 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)
commit6983dafa310afdb416af091578019e58a773984e
tree13ed227c1fc973df187e3f5b4d5889d850aa1a92
parent389b7f00c7396a3347743fcde5bbf0c00dd0cf71
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