[igt-dev] [PATCH i-g-t 1/3] tests/kms_color: Don't opencode igt_check_crc_equal()
Lyude
lyude at redhat.com
Wed Mar 17 22:42:20 UTC 2021
From: Lyude Paul <lyude at redhat.com>
Signed-off-by: Lyude Paul <lyude at redhat.com>
Cc: Martin Peres <martin.peres at free.fr>
Cc: Ben Skeggs <bskeggs at redhat.com>
Cc: Jeremy Cline <jcline at redhat.com>
---
tests/kms_color.c | 2 +-
tests/kms_color_helper.c | 6 ------
2 files changed, 1 insertion(+), 7 deletions(-)
diff --git a/tests/kms_color.c b/tests/kms_color.c
index f2686f57..705c9160 100644
--- a/tests/kms_color.c
+++ b/tests/kms_color.c
@@ -506,7 +506,7 @@ static bool test_pipe_ctm(data_t *data,
/* Verify that the CRC of the software computed output is
* equal to the CRC of the CTM matrix transformation output.
*/
- ret &= crc_equal(&crc_software, &crc_hardware);
+ ret &= !igt_skip_crc_compare || igt_check_crc_equal(&crc_software, &crc_hardware);
igt_plane_set_fb(primary, NULL);
igt_output_set_pipe(output, PIPE_NONE);
diff --git a/tests/kms_color_helper.c b/tests/kms_color_helper.c
index ac8e8454..5f223a88 100644
--- a/tests/kms_color_helper.c
+++ b/tests/kms_color_helper.c
@@ -245,12 +245,6 @@ get_blob(data_t *data, igt_pipe_t *pipe, enum igt_atomic_crtc_properties prop)
return drmModeGetPropertyBlob(data->drm_fd, prop_value);
}
-bool crc_equal(igt_crc_t *a, igt_crc_t *b)
-{
- return igt_skip_crc_compare ||
- memcmp(a->crc, b->crc, sizeof(a->crc[0]) * a->n_words) == 0;
-}
-
int
pipe_set_property_blob_id(igt_pipe_t *pipe,
enum igt_atomic_crtc_properties prop,
--
2.29.2
More information about the igt-dev
mailing list