]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915/selftests: Flush old resets between engines
authorChris Wilson <chris@chris-wilson.co.uk>
Mon, 5 Feb 2018 15:24:28 +0000 (15:24 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Mon, 5 Feb 2018 15:27:23 +0000 (15:27 +0000)
commitcc31b90c87f85da0f1f4aa26683cb52ff770dfc0
treee8aa3b39b4b27e08c9f65659b743c4d6fc2081c7
parent4e5bd024369014c09b4614dd799350100613dee7
drm/i915/selftests: Flush old resets between engines

When injecting rapid resets, we must be careful to at least wait for the
previous reset to have taken effect and the engine restarted. If we
perform a second reset before that has happened, we will notice that the
engine hasn't recovered and declare it lost, wedging the device and
failing. In practice, since we wait for each hanging batch to start
before injecting the reset, this too-fast-reset condition can only be
triggered when moving onto the next engine in the test, so we need only
wait for the existing reset to complete before switching engines.

v2: Wrap up the wait inside a safety net to bail out in case of angry hw.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
Cc: Michel Thierry <michel.thierry@intel.com>
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20180205152431.12163-1-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/selftests/intel_hangcheck.c