All of lore.kernel.org
 help / color / mirror / Atom feed
* [igt-dev] [PATCH i-g-t] tests/kms_plane_cursor: Wait for an extra vblank on AMD hw
@ 2022-10-20 21:08 Aurabindo Pillai
  2022-10-20 23:02 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Aurabindo Pillai @ 2022-10-20 21:08 UTC (permalink / raw)
  To: igt-dev

On AMD hardware, atomic cursor updates are not synchronized with the
same frame in the atomic code path, resulting in cursor programming
getting deferred to the next frame. Add a device specific quirk to
account for this delay.

Signed-off-by: Aurabindo Pillai <aurabindo.pillai@amd.com>
---
 tests/kms_plane_cursor.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/tests/kms_plane_cursor.c b/tests/kms_plane_cursor.c
index e9abfd78..5af390e0 100644
--- a/tests/kms_plane_cursor.c
+++ b/tests/kms_plane_cursor.c
@@ -169,6 +169,11 @@ static void test_cursor_pos(data_t *data, int x, int y, unsigned int flags)
 	igt_plane_set_position(data->cursor, x, y);
 	igt_display_commit_atomic(&data->display, 0, NULL);
 
+	/* Wait for one more vblank since cursor updates are not
+	 * synchronized to the same frame on AMD hw */
+	if(is_amdgpu_device(data->drm_fd))
+		igt_wait_for_vblank_count(data->drm_fd, data->display.pipes[data->pipe_id].crtc_offset, 1);
+
 	igt_pipe_crc_get_current(data->drm_fd, data->pipe_crc, &test_crc);
 	igt_pipe_crc_stop(data->pipe_crc);
 
-- 
2.38.0

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-10-21  7:17 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-20 21:08 [igt-dev] [PATCH i-g-t] tests/kms_plane_cursor: Wait for an extra vblank on AMD hw Aurabindo Pillai
2022-10-20 23:02 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
2022-10-21  3:55 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
2022-10-21  7:17 ` [igt-dev] [PATCH i-g-t] " Juha-Pekka Heikkila

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.