[igt-dev] [PATCH i-g-t] HAX tests/kms_rotation_crc

Juha-Pekka Heikkila juhapekka.heikkila at gmail.com
Fri Apr 26 09:11:37 UTC 2019


attempt to try to force rotation and scaling issues more visible.
If this test doesn't die it will pass regardless of anything.
---
 tests/intel-ci/fast-feedback.testlist | 264 +---------------------------------
 tests/kms_rotation_crc.c              |  48 ++++---
 2 files changed, 34 insertions(+), 278 deletions(-)

diff --git a/tests/intel-ci/fast-feedback.testlist b/tests/intel-ci/fast-feedback.testlist
index 40475b1..e75a929 100644
--- a/tests/intel-ci/fast-feedback.testlist
+++ b/tests/intel-ci/fast-feedback.testlist
@@ -1,261 +1,9 @@
 # Keep alphabetically sorted by default
 
-igt at core_auth@basic-auth
-igt at debugfs_test@read_all_entries
-igt at gem_basic@bad-close
-igt at gem_basic@create-close
-igt at gem_basic@create-fd-close
-igt at gem_busy@basic-busy-default
-igt at gem_close_race@basic-process
-igt at gem_close_race@basic-threads
-igt at gem_cpu_reloc@basic
-igt at gem_ctx_create@basic
-igt at gem_ctx_create@basic-files
-igt at gem_ctx_exec@basic
-igt at gem_ctx_param@basic
-igt at gem_ctx_param@basic-default
-igt at gem_ctx_switch@basic-default
-igt at gem_exec_basic@basic-blt
-igt at gem_exec_basic@basic-bsd
-igt at gem_exec_basic@basic-bsd1
-igt at gem_exec_basic@basic-bsd2
-igt at gem_exec_basic@basic-default
-igt at gem_exec_basic@basic-render
-igt at gem_exec_basic@basic-vebox
-igt at gem_exec_basic@gtt-blt
-igt at gem_exec_basic@gtt-bsd
-igt at gem_exec_basic@gtt-bsd1
-igt at gem_exec_basic@gtt-bsd2
-igt at gem_exec_basic@gtt-default
-igt at gem_exec_basic@gtt-render
-igt at gem_exec_basic@gtt-vebox
-igt at gem_exec_basic@readonly-blt
-igt at gem_exec_basic@readonly-bsd
-igt at gem_exec_basic@readonly-bsd1
-igt at gem_exec_basic@readonly-bsd2
-igt at gem_exec_basic@readonly-default
-igt at gem_exec_basic@readonly-render
-igt at gem_exec_basic@readonly-vebox
-igt at gem_exec_create@basic
-igt at gem_exec_fence@basic-busy-default
-igt at gem_exec_fence@basic-wait-default
-igt at gem_exec_fence@basic-await-default
-igt at gem_exec_fence@nb-await-default
-igt at gem_exec_gttfill@basic
-igt at gem_exec_parallel@basic
-igt at gem_exec_parse@basic-allowed
-igt at gem_exec_parse@basic-rejected
-igt at gem_exec_reloc@basic-cpu
-igt at gem_exec_reloc@basic-gtt
-igt at gem_exec_reloc@basic-cpu-gtt
-igt at gem_exec_reloc@basic-gtt-cpu
-igt at gem_exec_reloc@basic-cpu-read
-igt at gem_exec_reloc@basic-gtt-read
-igt at gem_exec_reloc@basic-write-cpu
-igt at gem_exec_reloc@basic-write-gtt
-igt at gem_exec_reloc@basic-write-read
-igt at gem_exec_reloc@basic-cpu-noreloc
-igt at gem_exec_reloc@basic-gtt-noreloc
-igt at gem_exec_reloc@basic-cpu-gtt-noreloc
-igt at gem_exec_reloc@basic-gtt-cpu-noreloc
-igt at gem_exec_reloc@basic-cpu-read-noreloc
-igt at gem_exec_reloc@basic-gtt-read-noreloc
-igt at gem_exec_reloc@basic-write-cpu-noreloc
-igt at gem_exec_reloc@basic-write-gtt-noreloc
-igt at gem_exec_reloc@basic-write-read-noreloc
-igt at gem_exec_reloc@basic-cpu-active
-igt at gem_exec_reloc@basic-gtt-active
-igt at gem_exec_reloc@basic-cpu-gtt-active
-igt at gem_exec_reloc@basic-gtt-cpu-active
-igt at gem_exec_reloc@basic-cpu-read-active
-igt at gem_exec_reloc@basic-gtt-read-active
-igt at gem_exec_reloc@basic-write-cpu-active
-igt at gem_exec_reloc@basic-write-gtt-active
-igt at gem_exec_reloc@basic-write-read-active
-igt at gem_exec_reloc@basic-softpin
-igt at gem_exec_store@basic-all
-igt at gem_exec_store@basic-blt
-igt at gem_exec_store@basic-bsd
-igt at gem_exec_store@basic-bsd1
-igt at gem_exec_store@basic-bsd2
-igt at gem_exec_store@basic-default
-igt at gem_exec_store@basic-render
-igt at gem_exec_store@basic-vebox
-igt at gem_exec_suspend@basic
-igt at gem_exec_suspend@basic-s3
-igt at gem_exec_suspend@basic-s4-devices
-igt at gem_flink_basic@bad-flink
-igt at gem_flink_basic@bad-open
-igt at gem_flink_basic@basic
-igt at gem_flink_basic@double-flink
-igt at gem_flink_basic@flink-lifetime
-igt at gem_linear_blits@basic
-igt at gem_mmap@basic
-igt at gem_mmap@basic-small-bo
-igt at gem_mmap_gtt@basic
-igt at gem_mmap_gtt@basic-copy
-igt at gem_mmap_gtt@basic-read
-igt at gem_mmap_gtt@basic-read-no-prefault
-igt at gem_mmap_gtt@basic-read-write
-igt at gem_mmap_gtt@basic-read-write-distinct
-igt at gem_mmap_gtt@basic-short
-igt at gem_mmap_gtt@basic-small-bo
-igt at gem_mmap_gtt@basic-small-bo-tiledx
-igt at gem_mmap_gtt@basic-small-bo-tiledy
-igt at gem_mmap_gtt@basic-small-copy
-igt at gem_mmap_gtt@basic-small-copy-xy
-igt at gem_mmap_gtt@basic-wc
-igt at gem_mmap_gtt@basic-write
-igt at gem_mmap_gtt@basic-write-cpu-read-gtt
-igt at gem_mmap_gtt@basic-write-gtt
-igt at gem_mmap_gtt@basic-write-gtt-no-prefault
-igt at gem_mmap_gtt@basic-write-no-prefault
-igt at gem_mmap_gtt@basic-write-read
-igt at gem_mmap_gtt@basic-write-read-distinct
-igt at gem_pread@basic
-igt at gem_pwrite@basic
-igt at gem_render_linear_blits@basic
-igt at gem_render_tiled_blits@basic
-igt at gem_ringfill@basic-default
-igt at gem_ringfill@basic-default-interruptible
-igt at gem_ringfill@basic-default-forked
-igt at gem_ringfill@basic-default-fd
-igt at gem_sync@basic-all
-igt at gem_sync@basic-each
-igt at gem_sync@basic-many-each
-igt at gem_sync@basic-store-all
-igt at gem_sync@basic-store-each
-igt at gem_tiled_blits@basic
-igt at gem_tiled_fence_blits@basic
-igt at gem_tiled_pread_basic
-igt at gem_wait@basic-busy-all
-igt at gem_wait@basic-wait-all
-igt at gem_wait@basic-await-all
-igt at gem_workarounds@basic-read
-igt at i915_getparams_basic@basic-eu-total
-igt at i915_getparams_basic@basic-subslice-total
-igt at i915_hangman@error-state-basic
-igt at kms_addfb_basic@addfb25-bad-modifier
-igt at kms_addfb_basic@addfb25-framebuffer-vs-set-tiling
-igt at kms_addfb_basic@addfb25-modifier-no-flag
-igt at kms_addfb_basic@addfb25-x-tiled
-igt at kms_addfb_basic@addfb25-x-tiled-mismatch
-igt at kms_addfb_basic@addfb25-yf-tiled
-igt at kms_addfb_basic@addfb25-y-tiled
-igt at kms_addfb_basic@addfb25-y-tiled-small
-igt at kms_addfb_basic@bad-pitch-0
-igt at kms_addfb_basic@bad-pitch-1024
-igt at kms_addfb_basic@bad-pitch-128
-igt at kms_addfb_basic@bad-pitch-256
-igt at kms_addfb_basic@bad-pitch-32
-igt at kms_addfb_basic@bad-pitch-63
-igt at kms_addfb_basic@bad-pitch-65536
-igt at kms_addfb_basic@bad-pitch-999
-igt at kms_addfb_basic@basic
-igt at kms_addfb_basic@basic-x-tiled
-igt at kms_addfb_basic@basic-y-tiled
-igt at kms_addfb_basic@bo-too-small
-igt at kms_addfb_basic@bo-too-small-due-to-tiling
-igt at kms_addfb_basic@clobberred-modifier
-igt at kms_addfb_basic@framebuffer-vs-set-tiling
-igt at kms_addfb_basic@invalid-get-prop
-igt at kms_addfb_basic@invalid-get-prop-any
-igt at kms_addfb_basic@invalid-set-prop
-igt at kms_addfb_basic@invalid-set-prop-any
-igt at kms_addfb_basic@no-handle
-igt at kms_addfb_basic@size-max
-igt at kms_addfb_basic@small-bo
-igt at kms_addfb_basic@tile-pitch-mismatch
-igt at kms_addfb_basic@too-high
-igt at kms_addfb_basic@too-wide
-igt at kms_addfb_basic@unused-handle
-igt at kms_addfb_basic@unused-modifier
-igt at kms_addfb_basic@unused-offsets
-igt at kms_addfb_basic@unused-pitches
-igt at kms_busy@basic-flip-a
-igt at kms_busy@basic-flip-b
-igt at kms_busy@basic-flip-c
-igt at kms_chamelium@dp-hpd-fast
-igt at kms_chamelium@dp-edid-read
-igt at kms_chamelium@dp-crc-fast
-igt at kms_chamelium@hdmi-hpd-fast
-igt at kms_chamelium@hdmi-edid-read
-igt at kms_chamelium@hdmi-crc-fast
-igt at kms_chamelium@vga-hpd-fast
-igt at kms_chamelium@vga-edid-read
-igt at kms_chamelium@common-hpd-after-suspend
-igt at kms_prop_blob@basic
-igt at kms_cursor_legacy@basic-busy-flip-before-cursor-atomic
-igt at kms_cursor_legacy@basic-busy-flip-before-cursor-legacy
-igt at kms_cursor_legacy@basic-flip-after-cursor-atomic
-igt at kms_cursor_legacy@basic-flip-after-cursor-legacy
-igt at kms_cursor_legacy@basic-flip-after-cursor-varying-size
-igt at kms_cursor_legacy@basic-flip-before-cursor-atomic
-igt at kms_cursor_legacy@basic-flip-before-cursor-legacy
-igt at kms_cursor_legacy@basic-flip-before-cursor-varying-size
-igt at kms_flip@basic-flip-vs-dpms
-igt at kms_flip@basic-flip-vs-modeset
-igt at kms_flip@basic-flip-vs-wf_vblank
-igt at kms_flip@basic-plain-flip
-igt at kms_force_connector_basic@force-connector-state
-igt at kms_force_connector_basic@force-edid
-igt at kms_force_connector_basic@force-load-detect
-igt at kms_force_connector_basic@prune-stale-modes
-igt at kms_frontbuffer_tracking@basic
-igt at kms_pipe_crc_basic@hang-read-crc-pipe-a
-igt at kms_pipe_crc_basic@nonblocking-crc-pipe-a
-igt at kms_pipe_crc_basic@nonblocking-crc-pipe-a-frame-sequence
-igt at kms_pipe_crc_basic@read-crc-pipe-a
-igt at kms_pipe_crc_basic@read-crc-pipe-b
-igt at kms_pipe_crc_basic@read-crc-pipe-c
-igt at kms_pipe_crc_basic@read-crc-pipe-a-frame-sequence
-igt at kms_pipe_crc_basic@suspend-read-crc-pipe-a
-igt at kms_psr@primary_page_flip
-igt at kms_psr@cursor_plane_move
-igt at kms_psr@sprite_plane_onoff
-igt at kms_psr@primary_mmap_gtt
-igt at kms_setmode@basic-clone-single-crtc
-igt at i915_pm_backlight@basic-brightness
-igt at i915_pm_rpm@basic-pci-d3-state
-igt at i915_pm_rpm@basic-rte
-igt at i915_pm_rps@basic-api
-igt at prime_busy@basic-after-default
-igt at prime_busy@basic-before-default
-igt at prime_busy@basic-wait-after-default
-igt at prime_busy@basic-wait-before-default
-igt at prime_self_import@basic-llseek-bad
-igt at prime_self_import@basic-llseek-size
-igt at prime_self_import@basic-with_fd_dup
-igt at prime_self_import@basic-with_one_bo
-igt at prime_self_import@basic-with_one_bo_two_files
-igt at prime_self_import@basic-with_two_bos
-igt at prime_vgem@basic-busy-default
-igt at prime_vgem@basic-fence-flip
-igt at prime_vgem@basic-fence-mmap
-igt at prime_vgem@basic-fence-read
-igt at prime_vgem@basic-fence-wait-default
-igt at prime_vgem@basic-gtt
-igt at prime_vgem@basic-read
-igt at prime_vgem@basic-sync-default
-igt at prime_vgem@basic-wait-default
-igt at prime_vgem@basic-write
-igt at vgem_basic@setversion
-igt at vgem_basic@create
-igt at vgem_basic@debugfs
-igt at vgem_basic@dmabuf-export
-igt at vgem_basic@dmabuf-fence
-igt at vgem_basic@dmabuf-fence-before
-igt at vgem_basic@dmabuf-mmap
-igt at vgem_basic@mmap
-igt at vgem_basic@second-client
-igt at vgem_basic@sysfs
+igt at kms_rotation_crc@multiplane-rotation
+igt at kms_rotation_crc@multiplane-rotation
+igt at kms_rotation_crc@multiplane-rotation
+igt at kms_rotation_crc@multiplane-rotation
+igt at kms_rotation_crc@multiplane-rotation
+igt at kms_rotation_crc@multiplane-rotation
 
-# All tests that do module unloading and reloading are executed last.
-# They will sometimes reveal issues of earlier tests leaving the
-# driver in a broken state that is not otherwise noticed in that test.
-
-igt at vgem_basic@unload
-igt at i915_module_load@reload
-igt at i915_module_load@reload-no-display
-igt at i915_module_load@reload-with-fault-injection
-igt at i915_pm_rpm@module-reload
diff --git a/tests/kms_rotation_crc.c b/tests/kms_rotation_crc.c
index fc995d0..8ac590b 100644
--- a/tests/kms_rotation_crc.c
+++ b/tests/kms_rotation_crc.c
@@ -457,7 +457,7 @@ static bool get_multiplane_crc(data_t *data, igt_output_t *output,
 					      planeinfo[c].tiling))
 			return false;
 
-		igt_create_fb(data->gfx_fd, w, h, planeinfo[c].format,
+		igt_create_fb(data->gfx_fd, (w)& ~3, (h)& ~3, planeinfo[c].format,
 			      planeinfo[c].tiling, &planes[c].fb);
 
 		paint_squares(data, planeinfo[c].rotation_sw, &planes[c].fb, 1.0f);
@@ -465,19 +465,27 @@ static bool get_multiplane_crc(data_t *data, igt_output_t *output,
 
 		if (planeinfo[c].rotation_hw & (IGT_ROTATION_90 | IGT_ROTATION_270))
 			igt_plane_set_size(planes[c].plane, h, w);
+		else
+		{
+			igt_plane_set_size(planes[c].plane, w, h);
 
-		igt_plane_set_position(planes[c].plane, planeinfo[c].x1, planeinfo[c].y1);
+		}
+		
+
+		igt_plane_set_position(planes[c].plane, 0, 0);
 		igt_plane_set_rotation(planes[c].plane, planeinfo[c].rotation_hw);
 	}
 
 	ret = igt_display_try_commit2(display, COMMIT_ATOMIC);
 	igt_assert_eq(ret, 0);
 
-	igt_pipe_crc_get_current(data->gfx_fd, data->pipe_crc, crc_output);
+//	igt_pipe_crc_get_current(data->gfx_fd, data->pipe_crc, crc_output);
 
 	for (c = 0; c < numplanes && oldplanes; c++)
 		igt_remove_fb(data->gfx_fd, &oldplanes[c].fb);
 
+	ret = igt_display_try_commit2(display, COMMIT_ATOMIC);
+
 	free(oldplanes);
 	data->multiplaneoldview = (void*)planes;
 	return true;
@@ -534,14 +542,14 @@ static void test_multi_plane_rotation(data_t *data, enum pipe pipe)
 		float_t height;
 		uint64_t tiling;
 	} planeconfigs[] = {
-	{IGT_ROTATION_0, .2f, .4f, LOCAL_DRM_FORMAT_MOD_NONE },
-	{IGT_ROTATION_0, .2f, .4f, LOCAL_I915_FORMAT_MOD_X_TILED },
-	{IGT_ROTATION_0, .2f, .4f, LOCAL_I915_FORMAT_MOD_Y_TILED },
-	{IGT_ROTATION_0, .2f, .4f, LOCAL_I915_FORMAT_MOD_Yf_TILED },
+//	{IGT_ROTATION_0, .2f, .4f, LOCAL_DRM_FORMAT_MOD_NONE },
+//	{IGT_ROTATION_0, .2f, .4f, LOCAL_I915_FORMAT_MOD_X_TILED },
+//	{IGT_ROTATION_0, .2f, .4f, LOCAL_I915_FORMAT_MOD_Y_TILED },
+//	{IGT_ROTATION_0, .2f, .4f, LOCAL_I915_FORMAT_MOD_Yf_TILED },
 	{IGT_ROTATION_90, .2f, .4f, LOCAL_I915_FORMAT_MOD_Y_TILED },
 	{IGT_ROTATION_90, .2f, .4f, LOCAL_I915_FORMAT_MOD_Yf_TILED },
-	{IGT_ROTATION_180, .2f, .4f, LOCAL_DRM_FORMAT_MOD_NONE },
-	{IGT_ROTATION_180, .2f, .4f, LOCAL_I915_FORMAT_MOD_X_TILED },
+//	{IGT_ROTATION_180, .2f, .4f, LOCAL_DRM_FORMAT_MOD_NONE },
+//	{IGT_ROTATION_180, .2f, .4f, LOCAL_I915_FORMAT_MOD_X_TILED },
 	{IGT_ROTATION_180, .2f, .4f, LOCAL_I915_FORMAT_MOD_Y_TILED },
 	{IGT_ROTATION_180, .2f, .4f, LOCAL_I915_FORMAT_MOD_Yf_TILED },
 	{IGT_ROTATION_270, .2f, .4f, LOCAL_I915_FORMAT_MOD_Y_TILED },
@@ -553,7 +561,7 @@ static void test_multi_plane_rotation(data_t *data, enum pipe pipe)
 	* case with tiling are 2 bpp, 4 bpp and NV12.
 	*/
 	static const uint32_t formatlist[] = {DRM_FORMAT_RGB565,
-		DRM_FORMAT_XRGB8888, DRM_FORMAT_NV12};
+		DRM_FORMAT_XRGB8888, DRM_FORMAT_YUYV, DRM_FORMAT_YVYU, DRM_FORMAT_NV12};
 
 	for_each_valid_output_on_pipe(display, pipe, output) {
 		int i, j, k, l;
@@ -562,14 +570,14 @@ static void test_multi_plane_rotation(data_t *data, enum pipe pipe)
 		igt_display_require_output(display);
 		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);
+//		data->pipe_crc = igt_pipe_crc_new(data->gfx_fd, pipe,
+//						  INTEL_PIPE_CRC_SOURCE_AUTO);
+//		igt_pipe_crc_start(data->pipe_crc);
 
 		for (i = 0; i < ARRAY_SIZE(planeconfigs); i++) {
 			p[0].planetype = DRM_PLANE_TYPE_PRIMARY;
-			p[0].width = (uint64_t)(planeconfigs[i].width * mode->hdisplay);
-			p[0].height = (uint64_t)(planeconfigs[i].height * mode->vdisplay);
+			p[0].width = (uint64_t)(mode->hdisplay);
+			p[0].height = (uint64_t)(mode->vdisplay);
 			p[0].tiling = planeconfigs[i].tiling;
 			pointlocation(data, (planeinfos *)&p, mode, 0);
 
@@ -578,8 +586,8 @@ static void test_multi_plane_rotation(data_t *data, enum pipe pipe)
 
 				for (j = 0; j < ARRAY_SIZE(planeconfigs); j++) {
 					p[1].planetype = DRM_PLANE_TYPE_OVERLAY;
-					p[1].width = (uint64_t)(planeconfigs[j].width * mode->hdisplay);
-					p[1].height = (uint64_t)(planeconfigs[j].height * mode->vdisplay);
+					p[1].width = (uint64_t)(mode->hdisplay);
+					p[1].height = (uint64_t)(mode->vdisplay);
 					p[1].tiling = planeconfigs[j].tiling;
 					pointlocation(data, (planeinfos *)&p,
 						      mode, 1);
@@ -615,13 +623,13 @@ static void test_multi_plane_rotation(data_t *data, enum pipe pipe)
 								   (planeinfos *)&p, MAXMULTIPLANESAMOUNT))
 							continue;
 
-						igt_assert_crc_equal(&retcrc_sw, &retcrc_hw);
+//						igt_assert_crc_equal(&retcrc_sw, &retcrc_hw);
 					}
 				}
 			}
 		}
-		igt_pipe_crc_stop(data->pipe_crc);
-		igt_pipe_crc_free(data->pipe_crc);
+//		igt_pipe_crc_stop(data->pipe_crc);
+//		igt_pipe_crc_free(data->pipe_crc);
 		igt_output_set_pipe(output, PIPE_ANY);
 	}
 
-- 
2.7.4



More information about the igt-dev mailing list