[PATCH v3 16/19] tests/amdgpu: disable check for IP presense with no kernel queue

Sunil Khatri sunil.khatri at amd.com
Fri Mar 28 08:24:13 UTC 2025


With kernel queues disabled num_rings will be reported zero.
Enforce the condition to be always true till the time
we have IOCTL to read this information from kernel.

Signed-off-by: Sunil Khatri <sunil.khatri at amd.com>
---
 tests/amdgpu/amd_basic.c  | 2 ++
 tests/amdgpu/amd_cs_nop.c | 4 +++-
 2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/tests/amdgpu/amd_basic.c b/tests/amdgpu/amd_basic.c
index 643a147f5..f8886fab8 100644
--- a/tests/amdgpu/amd_basic.c
+++ b/tests/amdgpu/amd_basic.c
@@ -788,6 +788,8 @@ igt_main
 		}
 	}
 
+	arr_cap[AMD_IP_GFX] = 1;
+	arr_cap[AMD_IP_COMPUTE] = 1;
 	igt_describe("Check-GFX-CS-for-every-available-ring-works-for-write-const-fill-and-copy-operation-using-more-than-one-IB-and-shared-IB");
 	igt_subtest_with_dynamic("cs-gfx-with-IP-GFX-UMQ") {
 		if (arr_cap[AMD_IP_GFX]) {
diff --git a/tests/amdgpu/amd_cs_nop.c b/tests/amdgpu/amd_cs_nop.c
index 96a15a029..0b7c29421 100644
--- a/tests/amdgpu/amd_cs_nop.c
+++ b/tests/amdgpu/amd_cs_nop.c
@@ -185,7 +185,7 @@ igt_main
 		for (e = engines; e->name; e++) {
 			igt_describe("Stressful-and-multiple-cs-of-nop-operations-using-multiple-processes-with-the-same-GPU-context");
 			igt_subtest_with_dynamic_f("cs-nops-with-%s-%s0", p->name, e->name) {
-				if (arr_cap[e->ip_type]) {
+				if (!arr_cap[e->ip_type]) {
 					igt_dynamic_f("cs-nop-with-%s-%s0", p->name, e->name)
 					nop_cs(device, context, e->name, e->ip_type, 0, 20,
 					       p->flags, 0);
@@ -194,6 +194,8 @@ igt_main
 		}
 	}
 
+	arr_cap[AMDGPU_HW_IP_GFX] = 1;
+	arr_cap[AMDGPU_HW_IP_COMPUTE] = 1;
 	for (p = phase; p->name; p++) {
 		for (e = engines; e->name; e++) {
 			igt_describe("Stressful-and-multiple-cs-of-nop-operations-using-multiple-processes-with-the-same-GPU-context-UMQ");
-- 
2.43.0



More information about the igt-dev mailing list