[PATCH i-g-t 3/4] lib/igt_draw: Ensure drawing is complete when draw_rect_render returns

Jouni Högander jouni.hogander at intel.com
Mon Apr 3 07:01:09 UTC 2023


Currently draw_rect_render is not ensuring drawing is complete when
it returns. This may lead e.g. crc mismatches if crc is taken too
early after starting the drawing. Fix this by calling intel_bb_sync
before return.

Signed-off-by: Jouni Högander <jouni.hogander at intel.com>
---
 lib/igt_draw.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lib/igt_draw.c b/lib/igt_draw.c
index ac512fac..217c3051 100644
--- a/lib/igt_draw.c
+++ b/lib/igt_draw.c
@@ -784,6 +784,7 @@ static void draw_rect_render(int fd, struct cmd_data *cmd_data,
 
 	rendercopy(ibb, src, 0, 0, rect->w, rect->h, dst, rect->x, rect->y);
 
+	intel_bb_sync(ibb);
 	intel_bb_destroy(ibb);
 	intel_buf_destroy(src);
 	intel_buf_destroy(dst);
-- 
2.34.1



More information about the Intel-gfx-trybot mailing list