]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915: Wait for all engines to be idle as part of i915_gem_wait_for_idle()
authorChris Wilson <chris@chris-wilson.co.uk>
Thu, 30 Mar 2017 14:50:39 +0000 (15:50 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Fri, 31 Mar 2017 11:07:17 +0000 (12:07 +0100)
commitbb6c9a750cd0d3eca909b2a4d5d65b9b24c637b0
tree2f68495691ae331d173170d0bb9ecaefe571b885
parentf2917c68fc422e32331c13cb48dd4adc7d3a0d72
drm/i915: Wait for all engines to be idle as part of i915_gem_wait_for_idle()

Make i915_gem_wait_for_idle() be a little heavier in order to try and
guarantee that the GPU is indeed idle (by checking each engine
individually is idle, i.e. all writes are complete and the rings
stopped) after waiting for in-flight requests to be completed.

v2: And return the final error.
v3: Break the wait_for() out from under the WARN -- the macro expansion
is hideous and unreadable in the warning message
v4: If wait_for_engine() fails the result is catastrophic, mark the
device as wedged and wait for the repair team.

References: https://bugs.freedesktop.org/show_bug.cgi?id=98836
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Link: http://patchwork.freedesktop.org/patch/msgid/20170330145041.9005-4-chris@chris-wilson.co.uk
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
drivers/gpu/drm/i915/i915_gem.c