All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH i-g-t v2] lib/igt_fb: fix intel modifiers for fb copying on xe driver
@ 2024-03-28 14:25 Juha-Pekka Heikkila
  2024-03-28 19:39 ` ✗ Fi.CI.BAT: failure for lib/igt_fb: fix intel modifiers for fb copying on xe driver (rev5) Patchwork
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Juha-Pekka Heikkila @ 2024-03-28 14:25 UTC (permalink / raw)
  To: igt-dev; +Cc: Juha-Pekka Heikkila, Bhanuprakash Modem

mc ccs need to go to vebox copy, blitter doesn't do mc ccs hence
on all platforms with ccs modifiers use engine copy for those.

Signed-off-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
---
v2: here fixed only mc ccs. Seems x-tile for legacy blitter will need to be
fixed elsewhere. This patch will allow mc ccs to be tested on dg2 with Xe
driver but on the same go reveal rc-ccs-cc is not working on igt side with
Xe and need to be looked at.

 lib/igt_fb.c | 16 +++++++++++-----
 1 file changed, 11 insertions(+), 5 deletions(-)

diff --git a/lib/igt_fb.c b/lib/igt_fb.c
index cc70cb91c..880fd08c9 100644
--- a/lib/igt_fb.c
+++ b/lib/igt_fb.c
@@ -2508,9 +2508,7 @@ static bool blitter_ok(const struct igt_fb *fb)
 	if (!is_intel_device(fb->fd))
 		return false;
 
-	if ((is_ccs_modifier(fb->modifier) &&
-	     !HAS_FLATCCS(intel_get_drm_devid(fb->fd))) ||
-	     is_gen12_mc_ccs_modifier(fb->modifier))
+	if (is_ccs_modifier(fb->modifier))
 		return false;
 
 	if (is_xe_device(fb->fd))
@@ -3062,7 +3060,12 @@ static void free_linear_mapping(struct fb_blit_upload *blit)
 		igt_nouveau_delete_bo(&linear->fb);
 	} else if (is_xe_device(fd)) {
 		gem_munmap(linear->map, linear->fb.size);
-		blitcopy(fb, &linear->fb);
+
+		if (blit->ibb)
+			copy_with_engine(blit, fb, &linear->fb);
+		else
+			blitcopy(fb, &linear->fb);
+
 		gem_close(fd, linear->fb.gem_handle);
 	} else {
 		gem_munmap(linear->map, linear->fb.size);
@@ -3142,7 +3145,10 @@ static void setup_linear_mapping(struct fb_blit_upload *blit)
 
 		linear->map = igt_nouveau_mmap_bo(&linear->fb, PROT_READ | PROT_WRITE);
 	} else if (is_xe_device(fd)) {
-		blitcopy(&linear->fb, fb);
+		if (blit->ibb)
+			copy_with_engine(blit, &linear->fb, fb);
+		else
+			blitcopy(&linear->fb, fb);
 
 		linear->map = xe_bo_mmap_ext(fd, linear->fb.gem_handle,
 					     linear->fb.size, PROT_READ | PROT_WRITE);
-- 
2.25.1


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

end of thread, other threads:[~2024-03-30 14:07 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-03-28 14:25 [PATCH i-g-t v2] lib/igt_fb: fix intel modifiers for fb copying on xe driver Juha-Pekka Heikkila
2024-03-28 19:39 ` ✗ Fi.CI.BAT: failure for lib/igt_fb: fix intel modifiers for fb copying on xe driver (rev5) Patchwork
2024-03-29 10:58 ` ✓ CI.xeBAT: success for lib/igt_fb: fix intel modifiers for fb copying on xe driver (rev6) Patchwork
2024-03-29 11:03 ` ✓ Fi.CI.BAT: " Patchwork
2024-03-30 14:07 ` ✗ Fi.CI.IGT: failure " Patchwork

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.