From b3a61c802872b4219699616f64dfcb572971afdd Mon Sep 17 00:00:00 2001 From: Daniel Vetter Date: Wed, 11 Sep 2013 10:47:07 +0200 Subject: lib/drmtest: skip when prefault control isn't available Instead of crashing with an igt_assert. Fixes the only crashing test when running igt on non-intel systems. Signed-off-by: Daniel Vetter --- lib/drmtest.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/drmtest.c') diff --git a/lib/drmtest.c b/lib/drmtest.c index ee74aa05..f1ee13c5 100644 --- a/lib/drmtest.c +++ b/lib/drmtest.c @@ -2040,7 +2040,7 @@ static void igt_prefault_control(bool enable) else index = 0; - igt_assert(write(fd, &buf[index], 1) == 1); + igt_require(write(fd, &buf[index], 1) == 1); close(fd); } @@ -2059,7 +2059,7 @@ void igt_disable_prefault(void) void igt_enable_prefault(void) { - return igt_prefault_control(true); + igt_prefault_control(true); } void igt_system_suspend_autoresume(void) -- cgit v1.2.3