diff options
author | Maarten Lankhorst <maarten.lankhorst@linux.intel.com> | 2018-04-05 12:46:22 +0200 |
---|---|---|
committer | Maarten Lankhorst <maarten.lankhorst@linux.intel.com> | 2018-04-11 09:45:37 +0200 |
commit | 2ef96ec9fd445b3ae3e172dacb76a4a0e8eb1bef (patch) | |
tree | 1ae87de10dbecd3ea270669f5f02da33d3274479 /lib/igt_debugfs.c | |
parent | aed2030ea1eeda27299db8994b329d3063559805 (diff) |
lib/igt_debugfs: Add timeouts to opening pipe CRC fd.
This will fix the PSR tests to fail slightly faster, since they wait
indefinitely for a CRC that never comes during open.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
[mlankhorst: Increase timeout to 10 seconds for HSW CRC w/a.]
Reviewed-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Diffstat (limited to 'lib/igt_debugfs.c')
-rw-r--r-- | lib/igt_debugfs.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/igt_debugfs.c b/lib/igt_debugfs.c index 8adc02e9..f3196f43 100644 --- a/lib/igt_debugfs.c +++ b/lib/igt_debugfs.c @@ -757,7 +757,10 @@ void igt_pipe_crc_start(igt_pipe_crc_t *pipe_crc) sprintf(buf, "crtc-%d/crc/data", pipe_crc->pipe); + igt_set_timeout(10, "Opening crc fd, which waits for first CRC."); pipe_crc->crc_fd = openat(pipe_crc->dir, buf, pipe_crc->flags); + igt_reset_timeout(); + igt_assert(pipe_crc->crc_fd != -1); errno = 0; } |