All of lore.kernel.org
 help / color / mirror / Atom feed
* [igt-dev] [PATCH i-g-t] tests/kms_big_fb: Add retry mechanism for async flip subtests
@ 2021-10-04  8:56 Karthik B S
  2021-10-04  9:19 ` Ville Syrjälä
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Karthik B S @ 2021-10-04  8:56 UTC (permalink / raw)
  To: igt-dev; +Cc: juha-pekka.heikkila, Karthik B S

Async flip subtests fail sporadically with CRC failure on CI.
This is expected as these tests are not run on highest priority by the
scheduler, but this creates noise on CI. Add retry mechanism to rerun
the test once if failure is seen.

Signed-off-by: Karthik B S <karthik.b.s@intel.com>
---
 tests/i915/kms_big_fb.c | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/tests/i915/kms_big_fb.c b/tests/i915/kms_big_fb.c
index 308227c9..8c09f59e 100644
--- a/tests/i915/kms_big_fb.c
+++ b/tests/i915/kms_big_fb.c
@@ -481,6 +481,7 @@ max_hw_stride_async_flip_test(data_t *data)
 		       h = data->output->config.default_mode.vdisplay;
 	igt_plane_t *primary;
 	igt_crc_t compare_crc, async_crc;
+	bool retried = false;
 
 	igt_require(data->display.is_atomic);
 	igt_output_set_pipe(data->output, data->pipe);
@@ -513,6 +514,7 @@ max_hw_stride_async_flip_test(data_t *data)
 					  INTEL_PIPE_CRC_SOURCE_AUTO);
 	igt_pipe_crc_start(data->pipe_crc);
 
+retry:
 	igt_set_timeout(5, "Async pageflipping loop got stuck!\n");
 	for (int i = 0; i < 2; i++) {
 		igt_plane_set_fb(primary, &data->big_fb);
@@ -548,6 +550,13 @@ max_hw_stride_async_flip_test(data_t *data)
 		igt_assert_f(kmstest_get_vblank(data->drm_fd, data->pipe, 0) -
 			     startframe == 1, "lost frames\n");
 
+		/* Test is not running at real time priority, so allow one failure*/
+		if (!(igt_check_crc_equal(&compare_crc, &async_crc)^(i^1)) && !retried) {
+			retried = true;
+			igt_reset_timeout();
+			goto retry;
+		}
+
 		igt_assert_f(igt_check_crc_equal(&compare_crc, &async_crc)^(i^1),
 			     "CRC failure with async flip, crc %s match for checked round\n",
 			     i?"should":"shouldn't");
-- 
2.22.0

^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2021-10-08 10:56 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-04  8:56 [igt-dev] [PATCH i-g-t] tests/kms_big_fb: Add retry mechanism for async flip subtests Karthik B S
2021-10-04  9:19 ` Ville Syrjälä
2021-10-04 15:43   ` Ville Syrjälä
2021-10-05 10:00     ` Karthik B S
2021-10-05 10:22       ` Ville Syrjälä
2021-10-05 10:46         ` Juha-Pekka Heikkila
2021-10-05 11:06           ` Ville Syrjälä
2021-10-08 10:56             ` Karthik B S
2021-10-04 13:31 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
2021-10-04 16:31 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.