[igt-dev] [PATCH i-g-t 4/4] tests/kms_plane: Ignore the crc frame count with --skip-crc-compare

Ville Syrjala ville.syrjala at linux.intel.com
Fri Apr 16 17:48:41 UTC 2021


From: Ville Syrjälä <ville.syrjala at linux.intel.com>

While debugging one might run things with "--interacive-debug=modeset
--skip-crc-compare" to actually see what things look like on the screen.
To do that without the asserts failing we need to ignore the crc frame
count value since we may be sitting there for an arbitrary amount of
time staring at the screen.

Signed-off-by: Ville Syrjälä <ville.syrjala at linux.intel.com>
---
 tests/kms_plane.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tests/kms_plane.c b/tests/kms_plane.c
index f20f5bee918b..9fe253a8c393 100644
--- a/tests/kms_plane.c
+++ b/tests/kms_plane.c
@@ -549,7 +549,8 @@ static void capture_crc(data_t *data, unsigned int vblank, igt_crc_t *crc)
 {
 	igt_pipe_crc_get_for_frame(data->drm_fd, data->pipe_crc, vblank, crc);
 
-	igt_fail_on_f(crc->has_valid_frame && crc->frame != vblank,
+	igt_fail_on_f(!igt_skip_crc_compare &&
+		      crc->has_valid_frame && crc->frame != vblank,
 		      "Got CRC for the wrong frame (got %u, expected %u). CRC buffer overflow?\n",
 		      crc->frame, vblank);
 }
-- 
2.26.3



More information about the igt-dev mailing list