[PATCH i-g-t] tests/xe_oa: Skip when no OA units available

Marcin Bernatowicz marcin.bernatowicz at linux.intel.com
Thu Feb 20 13:01:05 UTC 2025


Add a check to ensure at least one OA unit is available before
proceeding with the tests. This prevents unnecessary failures on
devices that do not support OA units.

Signed-off-by: Marcin Bernatowicz <marcin.bernatowicz at linux.intel.com>
Cc: Ashutosh Dixit <ashutosh.dixit at intel.com>
Cc: Jakub Kolakowski <jakub1.kolakowski at intel.com>
Cc: Umesh Nerlige Ramappa <umesh.nerlige.ramappa at intel.com>
---
 tests/intel/xe_oa.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/tests/intel/xe_oa.c b/tests/intel/xe_oa.c
index 0242fd594..6abf44128 100644
--- a/tests/intel/xe_oa.c
+++ b/tests/intel/xe_oa.c
@@ -4852,6 +4852,7 @@ igt_main
 
 		/* See xe_query_oa_units_new() */
 		igt_require(xe_dev->oa_units);
+		igt_require(xe_dev->oa_units->num_oa_units);
 		oau = nth_oa_unit(drm_fd, 0);
 
 		devid = intel_get_drm_devid(drm_fd);
-- 
2.31.1



More information about the igt-dev mailing list