[igt-dev] [PATCH i-g-t] tests/kms_plane_cursor: Wait for an extra vblank on AMD hw
Juha-Pekka Heikkila
juhapekka.heikkila at gmail.com
Fri Oct 21 07:17:03 UTC 2022
Reviewed-by: Juha-Pekka Heikkila <juhapekka.heikkila at gmail.com>
On 21.10.2022 0.08, Aurabindo Pillai wrote:
> 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 at 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);
>
More information about the igt-dev
mailing list