[PATCH 4/5] drm/i915/selftests: Don't use -ETIMEDOUT from inside a test

Chris Wilson chris at chris-wilson.co.uk
Tue Apr 17 17:37:32 UTC 2018


-ETIMEDOUT is reserved in the selftests for use by igt_timeout, and the
errno is magically handled by the test runner to break from inside the
test loop without propagating back to userspace as a failure. So convert
the -ETIMEDOUT from wait_var_event_timeout() into another errno.

Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
---
 drivers/gpu/drm/i915/selftests/intel_breadcrumbs.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/gpu/drm/i915/selftests/intel_breadcrumbs.c b/drivers/gpu/drm/i915/selftests/intel_breadcrumbs.c
index 46580026c7fc..0a12e81a45dd 100644
--- a/drivers/gpu/drm/i915/selftests/intel_breadcrumbs.c
+++ b/drivers/gpu/drm/i915/selftests/intel_breadcrumbs.c
@@ -416,6 +416,7 @@ static int igt_wakeup(void *arg)
 		if (err) {
 			pr_err("Timed out waiting for %d remaining waiters\n",
 			       atomic_read(&done));
+			err = -ENXIO; /* -ETIMEDOUT is reserved */
 			break;
 		}
 
-- 
2.17.0



More information about the Intel-gfx-trybot mailing list