summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2013-10-31 14:02:44 +0100
committerDaniel Vetter <daniel.vetter@ffwll.ch>2013-11-01 20:43:15 +0100
commit842007154da76dc2684077a4080c875bb3068f32 (patch)
treedb62c34630cb11cbfeef8f9f37569558a43dd32b /tests
parent0b51de8dd02dc2502fa0614c3a29959a066584cc (diff)
tests: use "auto" pipe CRC source
Makes stuff work on DP ports on gmch platforms automatically. Cc: Damien Lespiau <damien.lespiau@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'tests')
-rw-r--r--tests/debugfs_pipe_crc.c11
-rw-r--r--tests/kms_cursor_crc.c12
2 files changed, 5 insertions, 18 deletions
diff --git a/tests/debugfs_pipe_crc.c b/tests/debugfs_pipe_crc.c
index 83e031e7..a242a5b3 100644
--- a/tests/debugfs_pipe_crc.c
+++ b/tests/debugfs_pipe_crc.c
@@ -169,17 +169,12 @@ static void test_read_crc(data_t *data, int pipe, unsigned flags)
pipe_crc = igt_pipe_crc_new(&data->debugfs, data->drm_fd,
connector->config.pipe,
- INTEL_PIPE_CRC_SOURCE_PLANE1);
+ INTEL_PIPE_CRC_SOURCE_AUTO);
connector_set_mode(data, connector, &connector->config.default_mode);
- if (!pipe_crc || !igt_pipe_crc_start(pipe_crc)) {
- igt_pipe_crc_free(pipe_crc);
- pipe_crc = igt_pipe_crc_new(&data->debugfs, data->drm_fd,
- connector->config.pipe,
- INTEL_PIPE_CRC_SOURCE_PIPE);
- igt_assert(igt_pipe_crc_start(pipe_crc));
- }
+ igt_require(pipe_crc);
+ igt_assert(igt_pipe_crc_start(pipe_crc));
/* wait for 3 vblanks and the corresponding 3 CRCs */
igt_pipe_crc_get_crcs(pipe_crc, 3, &crcs);
diff --git a/tests/kms_cursor_crc.c b/tests/kms_cursor_crc.c
index 3828ac33..55b9b7c8 100644
--- a/tests/kms_cursor_crc.c
+++ b/tests/kms_cursor_crc.c
@@ -110,16 +110,8 @@ static igt_pipe_crc_t *create_crc(data_t *data, int crtc_idx)
igt_pipe_crc_t *crc;
crc = igt_pipe_crc_new(&data->debugfs, data->drm_fd, crtc_idx,
- INTEL_PIPE_CRC_SOURCE_PF);
- if (crc)
- return crc;
-
- crc = igt_pipe_crc_new(&data->debugfs, data->drm_fd, crtc_idx,
- INTEL_PIPE_CRC_SOURCE_PIPE);
- if (crc)
- return crc;
-
- return NULL;
+ INTEL_PIPE_CRC_SOURCE_AUTO);
+ return crc;
}
static void display_init(data_t *data)