mirror of
https://github.com/tiagovignatti/intel-gpu-tools.git
synced 2025-06-09 08:56:11 +00:00
tests/kms_flip: add a timeout for the nonblocking-read test
kms_flip/nonblocking-read will block indefinitely if it fails, so introduce a timeout to indicate test failure. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=85718 Signed-off-by: Thomas Wood <thomas.wood@intel.com>
This commit is contained in:
parent
34424138bc
commit
f6aa80ca18
@ -1521,7 +1521,9 @@ static void test_nonblocking_read(int in)
|
|||||||
}
|
}
|
||||||
igt_require(ret != -1);
|
igt_require(ret != -1);
|
||||||
|
|
||||||
|
igt_set_timeout(5);
|
||||||
ret = read(fd, buffer, sizeof(buffer));
|
ret = read(fd, buffer, sizeof(buffer));
|
||||||
|
igt_set_timeout(0);
|
||||||
igt_assert_eq(ret, -1);
|
igt_assert_eq(ret, -1);
|
||||||
igt_assert_eq(errno, EAGAIN);
|
igt_assert_eq(errno, EAGAIN);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user