public inbox for igt-dev@lists.freedesktop.org
 help / color / mirror / Atom feed
* [PATCH i-g-t] tests/kms_cursor_legacy: Prefer tile4 modifier when supported
@ 2026-03-16  3:38 Jeevan B
  2026-03-16  5:17 ` ✓ Xe.CI.BAT: success for " Patchwork
                   ` (9 more replies)
  0 siblings, 10 replies; 15+ messages in thread
From: Jeevan B @ 2026-03-16  3:38 UTC (permalink / raw)
  To: igt-dev; +Cc: ramanaidu.naladala, Jeevan B

While creating the framebuffer, prefer tile4 when it is supported
instead of always using linear. Fall back to linear if tile4 is not
available.

Signed-off-by: Jeevan B <jeevan.b@intel.com>
---
 tests/kms_cursor_legacy.c | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/tests/kms_cursor_legacy.c b/tests/kms_cursor_legacy.c
index 5399ef481..4c4e477a1 100644
--- a/tests/kms_cursor_legacy.c
+++ b/tests/kms_cursor_legacy.c
@@ -367,15 +367,21 @@ static void set_fb_on_crtc(igt_display_t *display, igt_crtc_t *crtc,
 {
 	drmModeModeInfoPtr mode;
 	igt_plane_t *primary;
+	uint64_t modifier = DRM_FORMAT_MOD_LINEAR;
 
 	igt_output_set_crtc(output, crtc);
 	mode = igt_output_get_mode(output);
 
+	primary = igt_output_get_plane_type(output, DRM_PLANE_TYPE_PRIMARY);
+
+	if (igt_plane_has_format_mod(primary, DRM_FORMAT_XRGB8888,
+				     I915_FORMAT_MOD_4_TILED))
+		modifier = I915_FORMAT_MOD_4_TILED;
+
 	igt_create_pattern_fb(display->drm_fd,
 		      mode->hdisplay, mode->vdisplay,
-		      DRM_FORMAT_XRGB8888, DRM_FORMAT_MOD_LINEAR, fb_info);
+		      DRM_FORMAT_XRGB8888, modifier, fb_info);
 
-	primary = igt_output_get_plane_type(output, DRM_PLANE_TYPE_PRIMARY);
 	igt_plane_set_fb(primary, fb_info);
 }
 
-- 
2.43.0


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

end of thread, other threads:[~2026-04-06  6:13 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-16  3:38 [PATCH i-g-t] tests/kms_cursor_legacy: Prefer tile4 modifier when supported Jeevan B
2026-03-16  5:17 ` ✓ Xe.CI.BAT: success for " Patchwork
2026-03-16  5:23 ` ✗ i915.CI.BAT: failure " Patchwork
2026-03-16  7:22 ` ✗ Xe.CI.FULL: " Patchwork
2026-03-16  8:07 ` [PATCH i-g-t] " Naladala, Ramanaidu
2026-03-16  8:15 ` Naladala, Ramanaidu
2026-03-16 14:44 ` Ville Syrjälä
2026-03-16 17:27   ` B, Jeevan
2026-03-17 19:44     ` Naladala, Ramanaidu
2026-03-18  4:19       ` B, Jeevan
2026-03-18  9:44     ` Ville Syrjälä
2026-04-06  4:08 ` ✓ Xe.CI.BAT: success for tests/kms_cursor_legacy: Prefer tile4 modifier when supported (rev2) Patchwork
2026-04-06  4:19 ` ✓ i915.CI.BAT: " Patchwork
2026-04-06  5:13 ` ✓ Xe.CI.FULL: " Patchwork
2026-04-06  6:12 ` ✗ i915.CI.Full: failure " Patchwork

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox