Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Bhanuprakash Modem <bhanuprakash.modem@intel.com>
To: igt-dev@lists.freedesktop.org
Cc: Kunal Joshi <kunal1.joshi@intel.com>
Subject: [igt-dev] [i-g-t 03/16] tests/kms_getfb: Extended ccs tests to support XE
Date: Thu, 24 Aug 2023 11:11:10 +0530	[thread overview]
Message-ID: <20230824054123.820518-4-bhanuprakash.modem@intel.com> (raw)
In-Reply-To: <20230824054123.820518-1-bhanuprakash.modem@intel.com>

Add support for ccs tests work on XE driver.

V2: - Update XE blocklist
V3: - New patch for blocklist changes

Fixes: 5fd20e72a (tests/kms_getfb: Add XE support)
Signed-off-by: Bhanuprakash Modem <bhanuprakash.modem@intel.com>
Reviewed-by: Kunal Joshi <kunal1.joshi@intel.com>
---
 tests/kms_getfb.c | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/tests/kms_getfb.c b/tests/kms_getfb.c
index f90e51d64..6ee58caab 100644
--- a/tests/kms_getfb.c
+++ b/tests/kms_getfb.c
@@ -48,6 +48,7 @@
 #include "i915/gem_create.h"
 #include "igt_device.h"
 #include "xe/xe_query.h"
+#include "xe/xe_ioctl.h"
 
 IGT_TEST_DESCRIPTION("Tests GETFB and GETFB2 ioctls.");
 
@@ -145,7 +146,10 @@ static void get_ccs_fb(int fd, struct drm_mode_fb_cmd2 *ret)
 		size += add.pitches[1] * ALIGN(ALIGN(add.height, 16) / 16, 32);
 	}
 
-	add.handles[0] = gem_buffer_create_fb_obj(fd, size);
+	if (is_i915_device(fd))
+		add.handles[0] = gem_buffer_create_fb_obj(fd, size);
+	else
+		add.handles[0] = xe_bo_create_flags(fd, 0, size, vram_if_possible(fd, 0));
 	igt_require(add.handles[0] != 0);
 
 	if (!HAS_FLATCCS(devid))
@@ -315,7 +319,7 @@ static void test_duplicate_handles(int fd)
 		struct drm_mode_fb_cmd2 add_ccs = { };
 		struct drm_mode_fb_cmd get = { };
 
-		igt_require_i915(fd);
+		igt_require_intel(fd);
 		igt_require_f(!HAS_FLATCCS(intel_get_drm_devid(fd)),
 			      "skip because flat ccs has only one buffer.\n");
 
@@ -421,7 +425,7 @@ static void test_getfb2(int fd)
 		struct drm_mode_fb_cmd2 get = { };
 		int i;
 
-		igt_require_i915(fd);
+		igt_require_intel(fd);
 		get_ccs_fb(fd, &add_ccs);
 		igt_require(add_ccs.fb_id != 0);
 		get.fb_id = add_ccs.fb_id;
-- 
2.40.0

  parent reply	other threads:[~2023-08-24  5:49 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-24  5:41 [igt-dev] [i-g-t 00/16] Add tiling support for display tests Bhanuprakash Modem
2023-08-24  5:41 ` [igt-dev] [i-g-t 01/16] lib: Add tiling support for XE Bhanuprakash Modem
2023-08-24  5:41 ` [igt-dev] [i-g-t 02/16] tests/kms_cursor_edge_walk: Fix intel specific checks Bhanuprakash Modem
2023-08-24  5:41 ` Bhanuprakash Modem [this message]
2023-08-24  5:41 ` [igt-dev] [i-g-t 04/16] tests/kms_addfb_basic: Add tiling support for XE Bhanuprakash Modem
2023-08-24  5:41 ` [igt-dev] [i-g-t 05/16] tests/kms_plane: " Bhanuprakash Modem
2023-08-24  5:41 ` [igt-dev] [i-g-t 06/16] tests/kms_plane_lowres: " Bhanuprakash Modem
2023-08-24  5:41 ` [igt-dev] [i-g-t 07/16] tests/kms_plane_scaling: " Bhanuprakash Modem
2023-08-24  5:41 ` [igt-dev] [i-g-t 08/16] tests/kms_rotation_crc: " Bhanuprakash Modem
2023-08-24  5:41 ` [igt-dev] [i-g-t 09/16] tests/i915/kms_big_fb: " Bhanuprakash Modem
2023-08-24  5:41 ` [igt-dev] [i-g-t 10/16] tests/i915/kms_draw_crc: " Bhanuprakash Modem
2023-08-24  5:41 ` [igt-dev] [i-g-t 11/16] tests/i915/kms_flip_scaled_crc: " Bhanuprakash Modem
2023-08-24  5:41 ` [igt-dev] [i-g-t 12/16] tests/i915/kms_flip_tiling: " Bhanuprakash Modem
2023-08-24  5:41 ` [igt-dev] [i-g-t 13/16] tests/intel-ci: Drop tiling tests from xe blocklist Bhanuprakash Modem
2023-08-24  5:41 ` [igt-dev] [i-g-t 14/16] tests/intel-ci: Update Xe BAT & blocklist for kms FBT Bhanuprakash Modem
2023-08-24  5:41 ` [igt-dev] [i-g-t 15/16] tests/intel-ci: Add tiling tests to XE BAT Bhanuprakash Modem
2023-08-24  5:41 ` [igt-dev] [i-g-t 16/16] HAX: Run tiling tests in XE fast-feedback Bhanuprakash Modem
2023-08-24  6:03 ` [igt-dev] ✗ GitLab.Pipeline: warning for Add tiling support for display tests Patchwork
2023-08-24  6:22 ` [igt-dev] ✗ CI.xeBAT: failure " Patchwork
2023-08-24  6:30 ` [igt-dev] ✓ Fi.CI.BAT: success " Patchwork
2023-08-24 14:15 ` [igt-dev] ✗ Fi.CI.IGT: 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=20230824054123.820518-4-bhanuprakash.modem@intel.com \
    --to=bhanuprakash.modem@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=kunal1.joshi@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox