summaryrefslogtreecommitdiff
path: root/tests/kms_color.c
diff options
context:
space:
mode:
authorLyude Paul <lyude@redhat.com>2020-12-31 18:28:46 -0500
committerLyude Paul <lyude@redhat.com>2021-03-18 19:36:49 -0400
commit8c4a2cda2a92bdd87797969ef299ad7f6e8e993b (patch)
tree3df5630f6f1d8ca3d645a5e77c6e2bf064f840f7 /tests/kms_color.c
parentaed5cbf1179a180fde3fe0597ad7f34ee6954569 (diff)
tests/kms_color: Stop leaking fbs
While I was testing this out with nouveau, I noticed that this test leaks quite a lot of framebuffers. Didn't cause any issues, but we should fix this while we're at it. Signed-off-by: Lyude Paul <lyude@redhat.com> Reviewed-by: Martin Peres <martin.peres@mupuf.org> Cc: Ben Skeggs <bskeggs@redhat.com> Cc: Jeremy Cline <jcline@redhat.com>
Diffstat (limited to 'tests/kms_color.c')
-rw-r--r--tests/kms_color.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/kms_color.c b/tests/kms_color.c
index 02a1a2de..b1b91c74 100644
--- a/tests/kms_color.c
+++ b/tests/kms_color.c
@@ -105,6 +105,8 @@ static void test_pipe_degamma(data_t *data,
igt_plane_set_fb(primary, NULL);
igt_output_set_pipe(output, PIPE_NONE);
+ igt_remove_fb(data->drm_fd, &fb);
+ igt_remove_fb(data->drm_fd, &fb_modeset);
}
free_lut(degamma_linear);
@@ -189,6 +191,8 @@ static void test_pipe_gamma(data_t *data,
igt_plane_set_fb(primary, NULL);
igt_output_set_pipe(output, PIPE_NONE);
+ igt_remove_fb(data->drm_fd, &fb);
+ igt_remove_fb(data->drm_fd, &fb_modeset);
}
free_lut(gamma_full);
@@ -292,6 +296,8 @@ static void test_pipe_legacy_gamma(data_t *data,
igt_plane_set_fb(primary, NULL);
igt_output_set_pipe(output, PIPE_NONE);
+ igt_remove_fb(data->drm_fd, &fb);
+ igt_remove_fb(data->drm_fd, &fb_modeset);
}
free(red_lut);
@@ -510,6 +516,8 @@ static bool test_pipe_ctm(data_t *data,
igt_plane_set_fb(primary, NULL);
igt_output_set_pipe(output, PIPE_NONE);
+ igt_remove_fb(data->drm_fd, &fb);
+ igt_remove_fb(data->drm_fd, &fb_modeset);
}
free_lut(degamma_linear);
@@ -618,6 +626,9 @@ static void test_pipe_limited_range_ctm(data_t *data,
* equal to the CRC of the CTM matrix transformation output.
*/
igt_assert_crc_equal(&crc_full, &crc_limited);
+
+ igt_remove_fb(data->drm_fd, &fb);
+ igt_remove_fb(data->drm_fd, &fb_modeset);
}
free_lut(gamma_linear);