tests: Replace calls to igt_pipe_crc_drain + get_single with igt_pipe_crc_get_current()
This is a more race free of accomplishing the same.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
diff --git a/tests/kms_cursor_legacy.c b/tests/kms_cursor_legacy.c
index 85340d4..82ceebc 100644
--- a/tests/kms_cursor_legacy.c
+++ b/tests/kms_cursor_legacy.c
@@ -1334,8 +1334,7 @@
igt_assert_eq(get_vblank(display->drm_fd, pipe, 0), vblank_start);
- igt_pipe_crc_drain(pipe_crc);
- igt_pipe_crc_get_single(pipe_crc, &test_crc);
+ igt_pipe_crc_get_current(display->drm_fd, pipe_crc, &test_crc);
igt_spin_batch_free(display->drm_fd, spin);