[igt-dev] [PATCH i-g-t v10 03/15] lib/igt_draw: mark buffers as SCANOUT
Matthew Auld
matthew.auld at intel.com
Mon Nov 20 18:24:18 UTC 2023
Display buffers likely will want WC, instead of the default WB on the
CPU side, given that display engine is incoherent with CPU caches.
Signed-off-by: Matthew Auld <matthew.auld at intel.com>
Cc: José Roberto de Souza <jose.souza at intel.com>
Cc: Pallavi Mishra <pallavi.mishra at intel.com>
Reviewed-by: Pallavi Mishra <pallavi.mishra at intel.com>
---
lib/igt_draw.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/lib/igt_draw.c b/lib/igt_draw.c
index 498c69a56..dcaebee2f 100644
--- a/lib/igt_draw.c
+++ b/lib/igt_draw.c
@@ -797,7 +797,8 @@ static void draw_rect_render(int fd, struct cmd_data *cmd_data,
else
tmp.handle = xe_bo_create_flags(fd, 0,
ALIGN(tmp.size, xe_get_default_alignment(fd)),
- visible_vram_if_possible(fd, 0));
+ visible_vram_if_possible(fd, 0) |
+ DRM_XE_GEM_CREATE_FLAG_SCANOUT);
tmp.stride = rect->w * pixel_size;
tmp.bpp = buf->bpp;
--
2.42.0
More information about the igt-dev
mailing list