]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915: Stop spinning for DROP_IDLE (debugfs/i915_drop_caches)
authorChris Wilson <chris@chris-wilson.co.uk>
Tue, 7 May 2019 12:11:08 +0000 (13:11 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Tue, 7 May 2019 16:40:19 +0000 (17:40 +0100)
commit1bf032b1dd7059cc4a1ec358792e59440375ded0
treecbd7ebd1f84fbcd1399f86235fd9cbf07976ccc2
parentc3d1ef761084a6b72dd195514a4f14d65d4614de
drm/i915: Stop spinning for DROP_IDLE (debugfs/i915_drop_caches)

If the user is racing a call to debugfs/i915_drop_caches with ongoing
submission from another thread/process, we may never end up idling the
GPU and be uninterruptibly spinning in debugfs/i915_drop_caches trying
to catch an idle moment.

Just flush the work once, that should be enough to park the system under
correct conditions. Outside of those we either have a driver bug or the
user is racing themselves. Sadly, because the user may be provoking the
unwanted situation we can't put a warn here to attract attention to a
probable bug.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190507121108.18377-4-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/i915_debugfs.c