[igt-dev] [PATCH i-g-t 2/4] tests/kms_plane_multiple: Add tiled-none plane position subtests

Nicholas Kazlauskas nicholas.kazlauskas at amd.com
Tue Nov 13 15:23:48 UTC 2018


The per-pipe plane position subtests are capable of running on
AMDGPU as long as they're not using i915 specific tiling formats.

The test setup already supports being invoked with different tiling
modes so this patch introduces the new 'tiled-none' subtest that runs
without any tiling.

The tiled-none tests are skipped on i915 to retain existing test
coverage and behavior on i915.

Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas at amd.com>
---
 tests/kms_plane_multiple.c | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)

diff --git a/tests/kms_plane_multiple.c b/tests/kms_plane_multiple.c
index 721afe59..7c8adf94 100644
--- a/tests/kms_plane_multiple.c
+++ b/tests/kms_plane_multiple.c
@@ -291,12 +291,16 @@ test_plane_position(data_t *data, enum pipe pipe, uint64_t tiling)
 {
 	igt_output_t *output;
 	int connected_outs;
-	int devid = intel_get_drm_devid(data->drm_fd);
 	int n_planes = data->display.pipes[pipe].n_planes;
 
+	if (is_i915_device(data->drm_fd))
+		igt_skip_on(tiling == LOCAL_DRM_FORMAT_MOD_NONE);
+	else
+		igt_skip_on(tiling != LOCAL_DRM_FORMAT_MOD_NONE);
+
 	if ((tiling == LOCAL_I915_FORMAT_MOD_Y_TILED ||
 	     tiling == LOCAL_I915_FORMAT_MOD_Yf_TILED))
-		igt_require(AT_LEAST_GEN(devid, 9));
+		igt_require(AT_LEAST_GEN(intel_get_drm_devid(data->drm_fd), 9));
 
 	if (!opt.user_seed)
 		opt.seed = time(NULL);
@@ -344,6 +348,10 @@ run_tests_for_pipe(data_t *data, enum pipe pipe)
 	igt_subtest_f("atomic-pipe-%s-tiling-yf", kmstest_pipe_name(pipe))
 		for_each_valid_output_on_pipe(&data->display, pipe, output)
 			test_plane_position(data, pipe, LOCAL_I915_FORMAT_MOD_Yf_TILED);
+
+	igt_subtest_f("atomic-pipe-%s-tiling-none", kmstest_pipe_name(pipe))
+		for_each_valid_output_on_pipe(&data->display, pipe, output)
+			test_plane_position(data, pipe, LOCAL_DRM_FORMAT_MOD_NONE);
 }
 
 static data_t data;
-- 
2.17.1



More information about the igt-dev mailing list