summaryrefslogtreecommitdiff
path: root/tests/kms_rotation_crc.c
diff options
context:
space:
mode:
authorMaarten Lankhorst <maarten.lankhorst@linux.intel.com>2018-02-02 11:00:50 +0100
committerMaarten Lankhorst <maarten.lankhorst@linux.intel.com>2018-02-12 13:13:01 +0100
commitaa5068c58947f31252cad69d80686e40bbce29db (patch)
tree557e4984186b3b5abc17b8d1980190e1b4c9c233 /tests/kms_rotation_crc.c
parente62de1c7c4ecde0bea5256faec0e8793810f9410 (diff)
tests: Always call igt_remove_fb without checking.
This cleans up the tests slightly. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Reviewed-by: Mika Kahola <mika.kahola@intel.com> Tested-by: Vidya Srinivas <vidya.srinivas@intel.com>
Diffstat (limited to 'tests/kms_rotation_crc.c')
-rw-r--r--tests/kms_rotation_crc.c16
1 files changed, 2 insertions, 14 deletions
diff --git a/tests/kms_rotation_crc.c b/tests/kms_rotation_crc.c
index f65562ba..4f56d3d6 100644
--- a/tests/kms_rotation_crc.c
+++ b/tests/kms_rotation_crc.c
@@ -174,17 +174,10 @@ static void prepare_crtc(data_t *data, igt_output_t *output, enum pipe pipe,
static void remove_fbs(data_t *data)
{
- if (!data->fb.fb_id)
- return;
-
igt_remove_fb(data->gfx_fd, &data->fb);
igt_remove_fb(data->gfx_fd, &data->fb_reference);
igt_remove_fb(data->gfx_fd, &data->fb_unrotated);
-
- if (data->fb_flip.fb_id)
- igt_remove_fb(data->gfx_fd, &data->fb_flip);
-
- data->fb_flip.fb_id = data->fb.fb_id = 0;
+ igt_remove_fb(data->gfx_fd, &data->fb_flip);
}
enum rectangle_type {
@@ -205,12 +198,7 @@ static void prepare_fbs(data_t *data, igt_output_t *output,
uint32_t pixel_format = data->override_fmt ?: DRM_FORMAT_XRGB8888;
const float flip_opacity = 0.75;
- if (data->fb.fb_id) {
- igt_plane_set_fb(plane, NULL);
- igt_display_commit2(display, display->is_atomic ? COMMIT_ATOMIC : COMMIT_UNIVERSAL);
-
- remove_fbs(data);
- }
+ remove_fbs(data);
igt_plane_set_rotation(plane, IGT_ROTATION_0);