tests/intel/xe_exec_reset: fix mixed-engine reset stress to use actual GT engines
PATCH 1/1 tests/intel/xe_exec_reset: fix mixed-engine reset stress to use actual GT engines
From: Nishit Sharma <[email protected]>
This patch fixes the mixed-engine reset stress subtest by selecting only engine class/instance pairs that are actually exposed by the target GT instead of using a hardcoded class list with engine instance 0.
I talked with Gajendra and he suggested this change to me, but I made a mistake and added his s-o-b instead of suggested-by, so resending this with correct tags
--- tests/intel/xe_exec_reset.c | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-)
tests/intel/xe_exec_reset.c +13 -10
@@ -702,17 +702,20 @@ static void bo_ctx_create(int fd, int gt, uint64_t addr, size_t bo_size,static void fill_mixed_engine (struct gt_thread_data *t,int iter,struct drm_xe_engine_class_instance *instance) { -const uint16_t classes[] = { -DRM_XE_ENGINE_CLASS_COPY , -DRM_XE_ENGINE_CLASS_RENDER , -DRM_XE_ENGINE_CLASS_COMPUTE , -DRM_XE_ENGINE_CLASS_VIDEO_DECODE , -DRM_XE_ENGINE_CLASS_VIDEO_ENHANCE , - }; +struct drm_xe_engine_class_instance *hwe; +struct drm_xe_engine_class_instance engines[64 ]; +int n =0 ; + +xe_for_each_engine (t->fd, hwe) { +if (hwe->gt_id != t->gt) +continue ; + engines[n++] = *hwe; +if (n ==ARRAY_SIZE (engines)) +break ; + } - instance->gt_id = t->gt; - instance->engine_instance =0 ; - instance->engine_class = classes[(iter + t->id) %ARRAY_SIZE (classes)]; +igt_assert_f (n >0 ,"GT %d exposes no engines\n" , t->gt); + *instance = engines[(iter + t->id) % n]; } static void pressure_bo_create(int fd, uint32_t vm, int gt,
Signature · 1 line
2.43.0
Hi nishit.sharma,
Quoted 8 lines · On 2026-09-07 at 09:51:05 +0000, [email protected] wrote:
From: Nishit Sharma <[email protected]>
This patch fixes the mixed-engine reset stress subtest by selecting only engine class/instance pairs that are actually exposed by the target GT instead of using a hardcoded class list with engine instance 0.
Signed-off-by Nishit Sharma <[email protected]>Suggested-by Gajendra Uttamchand <[email protected]>
Suggested-by should be before s-o-b.
Quoted 4 lines
I talked with Gajendra and he suggested this change to me, but I made a mistake and added his s-o-b instead of suggested-by, so resending this with correct tags
This should be after '---' line, it could be corrected at merge, LGTM
As it was already tested and you only corrected description, I will merge it.
Regards,
Kamil
Quoted 42 lines
--- tests/intel/xe_exec_reset.c | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-)tests/intel/xe_exec_reset.c +13
-10@@ -702,17 +702,20 @@ static void bo_ctx_create(int fd, int gt, uint64_t addr, size_t bo_size,static void fill_mixed_engine (struct gt_thread_data *t,int iter,struct drm_xe_engine_class_instance *instance) { -const uint16_t classes[] = { -DRM_XE_ENGINE_CLASS_COPY , -DRM_XE_ENGINE_CLASS_RENDER , -DRM_XE_ENGINE_CLASS_COMPUTE , -DRM_XE_ENGINE_CLASS_VIDEO_DECODE , -DRM_XE_ENGINE_CLASS_VIDEO_ENHANCE , - }; +struct drm_xe_engine_class_instance *hwe; +struct drm_xe_engine_class_instance engines[64 ]; +int n =0 ; + +xe_for_each_engine (t->fd, hwe) { +if (hwe->gt_id != t->gt) +continue ; + engines[n++] = *hwe; +if (n ==ARRAY_SIZE (engines)) +break ; + } - instance->gt_id = t->gt; - instance->engine_instance =0 ; - instance->engine_class = classes[(iter + t->id) %ARRAY_SIZE (classes)]; +igt_assert_f (n >0 ,"GT %d exposes no engines\n" , t->gt); + *instance = engines[(iter + t->id) % n]; } static void pressure_bo_create(int fd, uint32_t vm, int gt,Signature · 1 line
2.43.0
Patchwork
CI✗ Fi.CI.BAT: failure for tests/intel/xe_exec_reset: fix mixed-engine reset stress to use actual GT engines (rev2)
In reply to [email protected]== Series Details ==
== Series Details ==
Series: tests/intel/xe_exec_reset: fix mixed-engine reset stress to use actual GT engines (rev2)
URL : https://patchwork.freedesktop.org/series/173473/
State : failure
== Summary ==
Series 173473 revision 2 was fully merged or fully failed: no git log