From: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
To: intel-gfx@lists.freedesktop.org
Subject: [PATCH i-g-t v4 7/7] igt/kms_rotation_crc : Fix flip tests for sprite plane
Date: Fri, 29 Sep 2017 11:59:37 +0200 [thread overview]
Message-ID: <20170929095937.15702-8-maarten.lankhorst@linux.intel.com> (raw)
In-Reply-To: <20170929095937.15702-1-maarten.lankhorst@linux.intel.com>
This test was flipping the primary plane instead of the sprite plane.
Flip the correct plane to make the test pass properly.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=102691
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
---
tests/kms_rotation_crc.c | 23 +++++++++++++++++------
1 file changed, 17 insertions(+), 6 deletions(-)
diff --git a/tests/kms_rotation_crc.c b/tests/kms_rotation_crc.c
index 4932a0d44410..b8327dfa0d83 100644
--- a/tests/kms_rotation_crc.c
+++ b/tests/kms_rotation_crc.c
@@ -332,6 +332,9 @@ static void test_plane_rotation(data_t *data, int plane_type)
enum igt_commit_style commit = COMMIT_LEGACY;
int ret;
+ if (data->flips && plane_type != DRM_PLANE_TYPE_PRIMARY)
+ igt_require(data->display.is_atomic);
+
if (plane_type == DRM_PLANE_TYPE_PRIMARY || plane_type == DRM_PLANE_TYPE_CURSOR)
commit = COMMIT_UNIVERSAL;
@@ -390,12 +393,20 @@ static void test_plane_rotation(data_t *data, int plane_type)
* check CRC against that one as well.
*/
if (data->flips) {
- ret = drmModePageFlip(data->gfx_fd,
- output->config.crtc->crtc_id,
- data->fb_flip.fb_id,
- DRM_MODE_PAGE_FLIP_EVENT,
- NULL);
- igt_assert_eq(ret, 0);
+ igt_plane_set_fb(plane, &data->fb_flip);
+ if (data->rotation == IGT_ROTATION_90 || data->rotation == IGT_ROTATION_270)
+ igt_plane_set_size(plane, data->fb.height, data->fb.width);
+
+ if (plane_type != DRM_PLANE_TYPE_PRIMARY) {
+ igt_display_commit_atomic(display, DRM_MODE_PAGE_FLIP_EVENT | DRM_MODE_ATOMIC_NONBLOCK, NULL);
+ } else {
+ ret = drmModePageFlip(data->gfx_fd,
+ output->config.crtc->crtc_id,
+ data->fb_flip.fb_id,
+ DRM_MODE_PAGE_FLIP_EVENT,
+ NULL);
+ igt_assert_eq(ret, 0);
+ }
wait_for_pageflip(data->gfx_fd);
igt_pipe_crc_collect_crc(data->pipe_crc,
&crc_output);
--
2.14.1
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2017-09-29 9:59 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-29 9:59 [PATCH i-g-t v4 0/7] lib/igt_kms: Convert properties to be more atomic-like Maarten Lankhorst
2017-09-29 9:59 ` [PATCH i-g-t v4 1/7] tests: Stop looking at plane private members Maarten Lankhorst
2017-09-29 13:13 ` Mika Kahola
2017-10-02 9:31 ` Maarten Lankhorst
2017-09-29 9:59 ` [PATCH i-g-t v4 2/7] lib/igt_kms: Change output->pending_crtc_idx_mask to output->pending_pipe Maarten Lankhorst
2017-10-02 10:19 ` Mika Kahola
2017-09-29 9:59 ` [PATCH i-g-t v4 3/7] lib/igt_kms: Commit primary plane when a modeset is forced on a pipe Maarten Lankhorst
2017-10-02 11:02 ` Mika Kahola
2017-09-29 9:59 ` [PATCH i-g-t v4 4/7] lib/igt_kms: Rework connector properties to be more atomic, v2 Maarten Lankhorst
2017-10-02 12:22 ` Mika Kahola
2017-09-29 9:59 ` [PATCH i-g-t v4 5/7] lib/igt_kms: Rework plane properties to be more atomic, v4 Maarten Lankhorst
2017-10-03 12:05 ` Mika Kahola
2017-10-04 7:26 ` Maarten Lankhorst
2017-10-04 13:54 ` [PATCH i-g-t] lib/igt_kms: Rework plane properties to be more atomic, v5 Maarten Lankhorst
2017-09-29 9:59 ` [PATCH i-g-t v4 6/7] lib/igt_kms: Rework pipe properties to be more atomic, v4.1 Maarten Lankhorst
2017-10-03 7:45 ` [PATCH i-g-t] lib/igt_kms: Rework pipe properties to be more atomic, v5 Maarten Lankhorst
2017-10-04 13:55 ` [PATCH i-g-t] lib/igt_kms: Rework pipe properties to be more atomic, v6 Maarten Lankhorst
2017-09-29 9:59 ` Maarten Lankhorst [this message]
2017-09-29 10:58 ` [PATCH i-g-t v4 7/7] igt/kms_rotation_crc : Fix flip tests for sprite plane Mika Kahola
2017-09-29 11:03 ` ✓ Fi.CI.BAT: success for lib/igt_kms: Convert properties to be more atomic-like. (rev8) Patchwork
2017-09-29 12:13 ` ✗ Fi.CI.IGT: failure " Patchwork
2017-10-03 9:08 ` ✗ Fi.CI.BAT: failure for lib/igt_kms: Convert properties to be more atomic-like. (rev9) Patchwork
2017-10-03 10:22 ` Petri Latvala
2017-10-04 18:00 ` ✓ Fi.CI.BAT: success for lib/igt_kms: Convert properties to be more atomic-like. (rev11) Patchwork
2017-10-04 22:08 ` ✗ Fi.CI.IGT: warning " Patchwork
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170929095937.15702-8-maarten.lankhorst@linux.intel.com \
--to=maarten.lankhorst@linux.intel.com \
--cc=intel-gfx@lists.freedesktop.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox