summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorJuha-Pekka Heikkila <juhapekka.heikkila@gmail.com>2018-10-17 15:48:54 +0300
committerArkadiusz Hiler <arkadiusz.hiler@intel.com>2018-10-24 16:01:18 +0300
commitfce6109b879f720755399f37701eff30c646f89b (patch)
tree87e68205de803655e0c600769db140e1f5096aa1 /tests
parentfa6dbf8c048961356fd642df047cb58ab49309b2 (diff)
tests/kms_rotation_crc: Don't leave crc running
Leaving crc running nobody reading it may fail tests randomly with dmesg comment "*ERROR* Overflow of CRC buffer, userspace reads too slow." v2 (Maarten Lankhorst): Don't change clean up code but just add flag for starting crc and stop it at end of test. bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105748 Signed-off-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/kms_rotation_crc.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/tests/kms_rotation_crc.c b/tests/kms_rotation_crc.c
index c233ef651..366c2546e 100644
--- a/tests/kms_rotation_crc.c
+++ b/tests/kms_rotation_crc.c
@@ -142,7 +142,7 @@ static void cleanup_crtc(data_t *data)
}
static void prepare_crtc(data_t *data, igt_output_t *output, enum pipe pipe,
- igt_plane_t *plane)
+ igt_plane_t *plane, bool start_crc)
{
igt_display_t *display = &data->display;
@@ -156,7 +156,9 @@ static void prepare_crtc(data_t *data, igt_output_t *output, enum pipe pipe,
igt_display_commit2(display, COMMIT_ATOMIC);
data->pipe_crc = igt_pipe_crc_new(data->gfx_fd, pipe, INTEL_PIPE_CRC_SOURCE_AUTO);
- igt_pipe_crc_start(data->pipe_crc);
+
+ if (start_crc)
+ igt_pipe_crc_start(data->pipe_crc);
}
enum rectangle_type {
@@ -361,7 +363,7 @@ static void test_plane_rotation(data_t *data, int plane_type, bool test_bad_form
plane = igt_output_get_plane_type(output, plane_type);
igt_require(igt_plane_has_prop(plane, IGT_PLANE_ROTATION));
- prepare_crtc(data, output, pipe, plane);
+ prepare_crtc(data, output, pipe, plane, true);
for (i = 0; i < num_rectangle_types; i++) {
/* Unsupported on i915 */
@@ -389,6 +391,7 @@ static void test_plane_rotation(data_t *data, int plane_type, bool test_bad_form
data->override_fmt, test_bad_format);
}
}
+ igt_pipe_crc_stop(data->pipe_crc);
}
}
@@ -410,7 +413,8 @@ static void test_plane_rotation_exhaust_fences(data_t *data,
igt_require(igt_plane_has_prop(plane, IGT_PLANE_ROTATION));
- prepare_crtc(data, output, pipe, plane);
+ prepare_crtc(data, output, pipe, plane, false);
+
mode = igt_output_get_mode(output);
w = mode->hdisplay;
h = mode->vdisplay;