[PATCH 4/5] tests/intel/xe_exec_multi_queue: fix expected error for parallel queue creation

Xin Wang
2026-04-03T01:41:30Z

Multi-LRC capable engine classes (vcs, vecs) are able to process the
multi-queue create request and reject it with -EINVAL when num_placements
is greater than 1. Engine classes that do not support multi-LRC cannot
form a parallel queue at all and return -EOPNOTSUPP instead.

Use xe_engine_class_supports_multi_lrc() to pick the correct expected
error code rather than hard-coding -EINVAL for every engine class.

Signed-off-by: Xin Wang <x.wang@intel.com>
---
tests/intel/xe_exec_multi_queue.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tests/intel/xe_exec_multi_queue.c b/tests/intel/xe_exec_multi_queue.c
index b5ded0633..dca791fb5 100644
--- a/tests/intel/xe_exec_multi_queue.c
+++ b/tests/intel/xe_exec_multi_queue.c
@@ -113,7 +113,8 @@ __test_sanity(int fd, int gt, int class, bool preempt_mode)
/* Multi-Queue can't be a parallel queue */
multi_queue.value = DRM_XE_MULTI_GROUP_CREATE;
if (n > 1)
- igt_assert_eq(__xe_exec_queue_create(fd, vm, 2, 1, eci, ext, &val), -EINVAL);
+ igt_assert_eq(__xe_exec_queue_create(fd, vm, 2, 1, eci, ext, &val),
+ xe_engine_class_supports_multi_lrc(fd, class) ? -EINVAL : -EOPNOTSUPP);

/* Specifying multiple MULTI_GROUP property is invalid */
multi_queue.base.next_extension = to_user_pointer(&multi_queue);
--
2.43.0