[PATCH v5 20/37] lib/igt_fb: Allow any non-planar format for igt_copy_fb

Harry Wentland harry.wentland at amd.com
Mon Aug 19 20:58:06 UTC 2024


The function is able to handle any non-planar format. It's been
tested for XRGB8888 and XRGB2101010 so far but should work
for a wider range of formats.

Signed-off-by: Harry Wentland <harry.wentland at amd.com>
---
 lib/igt_fb.c | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/lib/igt_fb.c b/lib/igt_fb.c
index 1e0bad1b82a8..555642c9d9d4 100644
--- a/lib/igt_fb.c
+++ b/lib/igt_fb.c
@@ -2166,10 +2166,6 @@ unsigned int igt_copy_fb(int fd, struct igt_fb *src, struct igt_fb *fb)
 	if (src->num_planes != 1)
 		return -EINVAL;
 
-	/* TODO expand for other formats */
-	if (src->drm_format != DRM_FORMAT_XRGB8888)
-		return -EINVAL;
-
 	fb_id = igt_create_fb(fd, src->width, src->height, src->drm_format,
 			    src->modifier, fb);
 
-- 
2.46.0



More information about the igt-dev mailing list