Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 2/2 i-g-t] tests/amd_deadlock: add sdma negative test
@ 2024-08-28  8:34 Jesse.zhang@amd.com
  2024-08-28 19:24 ` vitaly prosyak
  0 siblings, 1 reply; 2+ messages in thread
From: Jesse.zhang@amd.com @ 2024-08-28  8:34 UTC (permalink / raw)
  To: igt-dev; +Cc: Vitaly Prosyak, Alex Deucher, Christian Koenig,
	Jesse.zhang@amd.com

To enhance the SDMA negative test,  add a few new tests.

Signed-off-by: Jesse Zhang <jesse.zhang@amd.com>
---
 tests/amdgpu/amd_deadlock.c | 28 ++++++++++++++++++++++++++++
 1 file changed, 28 insertions(+)

diff --git a/tests/amdgpu/amd_deadlock.c b/tests/amdgpu/amd_deadlock.c
index 96da49002..5dd3bf9f1 100644
--- a/tests/amdgpu/amd_deadlock.c
+++ b/tests/amdgpu/amd_deadlock.c
@@ -127,6 +127,34 @@ igt_main
 		}
 	}
 
+	igt_describe("Test-GPU-reset-by-sdma-badop-with-jobs");
+	igt_subtest_with_dynamic("amdgpu-deadlock-sdma-badop-test") {
+		if (arr_cap[AMD_IP_DMA]) {
+			igt_dynamic_f("amdgpu-deadlock-sdma-badop-test")
+			bad_access_helper(device, CMD_STREAM_EXEC_INVALID_OPCODE,
+					AMDGPU_HW_IP_DMA);
+		}
+	}
+
+
+	igt_describe("Test-GPU-reset-by-sdma-bad-addr-with-jobs");
+	igt_subtest_with_dynamic("amdgpu-deadlock-sdma-bad-addr-test") {
+		if (arr_cap[AMD_IP_DMA]) {
+			igt_dynamic_f("amdgpu-deadlock-sdma-bad-addr-test")
+			bad_access_helper(device, CMD_STREAM_TRANS_BAD_MEM_ADDRESS,
+					AMDGPU_HW_IP_DMA);
+		}
+	}
+
+	igt_describe("Test-GPU-reset-by-sdma-bad-length-with-jobs");
+	igt_subtest_with_dynamic("amdgpu-deadlock-sdma-bad-length-test") {
+		if (arr_cap[AMD_IP_DMA]) {
+			igt_dynamic_f("amdgpu-deadlock-sdma-bad-length-test")
+			bad_access_helper(device, CMD_STREAM_TRANS_BAD_MEM_ADDRESS,
+					AMDGPU_HW_IP_DMA);
+		}
+	}
+
 	igt_fixture {
 		amdgpu_device_deinitialize(device);
 		drm_close_driver(fd);
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH 2/2 i-g-t] tests/amd_deadlock: add sdma negative test
  2024-08-28  8:34 [PATCH 2/2 i-g-t] tests/amd_deadlock: add sdma negative test Jesse.zhang@amd.com
@ 2024-08-28 19:24 ` vitaly prosyak
  0 siblings, 0 replies; 2+ messages in thread
From: vitaly prosyak @ 2024-08-28 19:24 UTC (permalink / raw)
  To: Jesse.zhang@amd.com, igt-dev
  Cc: Vitaly Prosyak, Alex Deucher, Christian Koenig

Both patches look good to me. I'll merge them after they pass our CI checks. 

I've posted them for CI verification since you've added several SDMA resets, and these tests are executed unconditionally in our CI pipeline.

Reviewed-by Vitaly Prosyak <vitaly.prosyak@amd.com>


On 2024-08-28 04:34, Jesse.zhang@amd.com wrote:
> To enhance the SDMA negative test,  add a few new tests.
>
> Signed-off-by: Jesse Zhang <jesse.zhang@amd.com>
> ---
>  tests/amdgpu/amd_deadlock.c | 28 ++++++++++++++++++++++++++++
>  1 file changed, 28 insertions(+)
>
> diff --git a/tests/amdgpu/amd_deadlock.c b/tests/amdgpu/amd_deadlock.c
> index 96da49002..5dd3bf9f1 100644
> --- a/tests/amdgpu/amd_deadlock.c
> +++ b/tests/amdgpu/amd_deadlock.c
> @@ -127,6 +127,34 @@ igt_main
>  		}
>  	}
>  
> +	igt_describe("Test-GPU-reset-by-sdma-badop-with-jobs");
> +	igt_subtest_with_dynamic("amdgpu-deadlock-sdma-badop-test") {
> +		if (arr_cap[AMD_IP_DMA]) {
> +			igt_dynamic_f("amdgpu-deadlock-sdma-badop-test")
> +			bad_access_helper(device, CMD_STREAM_EXEC_INVALID_OPCODE,
> +					AMDGPU_HW_IP_DMA);
> +		}
> +	}
> +
> +
> +	igt_describe("Test-GPU-reset-by-sdma-bad-addr-with-jobs");
> +	igt_subtest_with_dynamic("amdgpu-deadlock-sdma-bad-addr-test") {
> +		if (arr_cap[AMD_IP_DMA]) {
> +			igt_dynamic_f("amdgpu-deadlock-sdma-bad-addr-test")
> +			bad_access_helper(device, CMD_STREAM_TRANS_BAD_MEM_ADDRESS,
> +					AMDGPU_HW_IP_DMA);
> +		}
> +	}
> +
> +	igt_describe("Test-GPU-reset-by-sdma-bad-length-with-jobs");
> +	igt_subtest_with_dynamic("amdgpu-deadlock-sdma-bad-length-test") {
> +		if (arr_cap[AMD_IP_DMA]) {
> +			igt_dynamic_f("amdgpu-deadlock-sdma-bad-length-test")
> +			bad_access_helper(device, CMD_STREAM_TRANS_BAD_MEM_ADDRESS,
> +					AMDGPU_HW_IP_DMA);
> +		}
> +	}
> +
>  	igt_fixture {
>  		amdgpu_device_deinitialize(device);
>  		drm_close_driver(fd);

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-08-28 19:24 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-08-28  8:34 [PATCH 2/2 i-g-t] tests/amd_deadlock: add sdma negative test Jesse.zhang@amd.com
2024-08-28 19:24 ` vitaly prosyak

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox