[PATCH i-g-t] tests/intel/kms_pm_rpm: Update cursor_fb3 framebuffer creation format
Jeevan B
jeevan.b at intel.com
Thu Dec 5 06:00:49 UTC 2024
Updated the cursor_fb3 framebuffer creation in the cursor subtest
function to use a supported tiling format, either X-tile or linear,
for supported platforms.
Signed-off-by: Jeevan B <jeevan.b at intel.com>
---
tests/intel/kms_pm_rpm.c | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/tests/intel/kms_pm_rpm.c b/tests/intel/kms_pm_rpm.c
index 990c50915..283911afb 100644
--- a/tests/intel/kms_pm_rpm.c
+++ b/tests/intel/kms_pm_rpm.c
@@ -1198,8 +1198,13 @@ static void cursor_subtest(bool dpms)
DRM_FORMAT_MOD_LINEAR, &cursor_fb1);
igt_create_fb(drm_fd, 64, 64, DRM_FORMAT_ARGB8888,
DRM_FORMAT_MOD_LINEAR, &cursor_fb2);
- igt_create_fb(drm_fd, 64, 64, DRM_FORMAT_XRGB8888,
- I915_FORMAT_MOD_X_TILED, &cursor_fb3);
+ if (igt_display_has_format_mod(&ms_data.display, DRM_FORMAT_XRGB8888,
+ I915_FORMAT_MOD_X_TILED))
+ igt_create_fb(drm_fd, 64, 64, DRM_FORMAT_XRGB8888,
+ I915_FORMAT_MOD_X_TILED, &cursor_fb3);
+ else
+ igt_create_fb(drm_fd, 64, 64, DRM_FORMAT_XRGB8888,
+ DRM_FORMAT_MOD_LINEAR, &cursor_fb3);
fill_igt_fb(&cursor_fb1, 0xFF00FFFF);
fill_igt_fb(&cursor_fb2, 0xFF00FF00);
--
2.25.1
More information about the igt-dev
mailing list