All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jeevan B <jeevan.b@intel.com>
To: igt-dev@lists.freedesktop.org
Cc: ramanaidu.naladala@intel.com, Jeevan B <jeevan.b@intel.com>
Subject: [PATCH i-g-t] tests/kms_cursor_legacy: Prefer tile4 modifier when supported
Date: Mon, 16 Mar 2026 09:08:07 +0530	[thread overview]
Message-ID: <20260316033807.24078-1-jeevan.b@intel.com> (raw)

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


             reply	other threads:[~2026-03-16  3:39 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-16  3:38 Jeevan B [this message]
2026-03-16  5:17 ` ✓ Xe.CI.BAT: success for tests/kms_cursor_legacy: Prefer tile4 modifier when supported 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-04-13  9:21         ` Maarten Lankhorst
2026-04-13  9:29           ` Ville Syrjälä
2026-04-13 10:28             ` Maarten Lankhorst
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

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260316033807.24078-1-jeevan.b@intel.com \
    --to=jeevan.b@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=ramanaidu.naladala@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.