On flushing the tests, we do so with a timeout to prevent waiting indefinitely. However, if we miss an interrupt, the timeout provides a safety net that still completes successfully (as we check the completion condition after reaching the timeout and see all is well). This safety net can unfortunately mask some bugs, so let's add a warning here so we don't just ignore it. Signed-off-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> Cc: Mika Kuoppala <mika.kuoppala@xxxxxxxxxxxxxxx> --- drivers/gpu/drm/i915/selftests/igt_flush_test.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/selftests/igt_flush_test.c b/drivers/gpu/drm/i915/selftests/igt_flush_test.c index af66e3d4e23a..da620ed7cc36 100644 --- a/drivers/gpu/drm/i915/selftests/igt_flush_test.c +++ b/drivers/gpu/drm/i915/selftests/igt_flush_test.c @@ -19,7 +19,8 @@ int igt_flush_test(struct drm_i915_private *i915, unsigned int flags) i915_gem_set_wedged(i915); } - if (i915_gem_wait_for_idle(i915, flags, HZ / 5) == -ETIME) { + switch (i915_gem_wait_for_idle(i915, flags, HZ / 5)) { + case -ETIME: pr_err("%pS timed out, cancelling all further testing.\n", __builtin_return_address(0)); @@ -27,6 +28,12 @@ int igt_flush_test(struct drm_i915_private *i915, unsigned int flags) GEM_TRACE_DUMP(); i915_gem_set_wedged(i915); + break; + + case 0: + pr_err("%pS missed idle-completion interrupt\n", + __builtin_return_address(0)); + break; } return i915_terminally_wedged(&i915->gpu_error) ? -EIO : 0; -- 2.18.0 _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx