Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: vitaly prosyak <vprosyak@amd.com>
To: "Jesse.zhang@amd.com" <jesse.zhang@amd.com>,
	igt-dev@lists.freedesktop.org
Cc: Vitaly Prosyak <vitaly.prosyak@amd.com>,
	Alex Deucher <alexander.deucher@amd.com>,
	Christian Koenig <christian.koenig@amd.com>,
	Kamil Konieczny <kamil.konieczny@linux.intel.com>
Subject: Re: [PATCH i-g-t] tests/amdgpu: print expect error information
Date: Fri, 13 Sep 2024 15:19:24 -0400	[thread overview]
Message-ID: <7e28cbdf-5c00-4275-a9f8-8433509ce177@amd.com> (raw)
In-Reply-To: <20240913100732.2271010-1-jesse.zhang@amd.com>

Thanks, the change looks good !

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

On 2024-09-13 06:07, Jesse.zhang@amd.com wrote:
> Because they are negative tests, some errors are expected.
> Print the expected errors for each test.
>
> Signed-off-by: Jesse Zhang <jesse.zhang@amd.com>
> ---
>  tests/amdgpu/amd_queue_reset.c | 13 ++++++++++++-
>  1 file changed, 12 insertions(+), 1 deletion(-)
>
> diff --git a/tests/amdgpu/amd_queue_reset.c b/tests/amdgpu/amd_queue_reset.c
> index 68575d496..bd0deb271 100644
> --- a/tests/amdgpu/amd_queue_reset.c
> +++ b/tests/amdgpu/amd_queue_reset.c
> @@ -1090,6 +1090,7 @@ igt_main
>  	unsigned int ring_id_bad;
>  	unsigned int ring_id_job_good;
>  	unsigned int ring_id_job_bad;
> +	int expect_error;
>  
>  	enum amd_ip_block_type ip_tests[2] = {AMD_IP_COMPUTE/*keep first*/, AMD_IP_GFX};
>  	enum amd_ip_block_type ip_background = AMD_IP_COMPUTE;
> @@ -1146,7 +1147,6 @@ igt_main
>  
>  		r = is_run_device_parameter_found(argc, argv);
>  		snprintf(shm_name,sizeof(shm_name),"/queue_reset_shm_%d",r);
> -
>  		fd = drm_open_driver(DRIVER_AMDGPU);
>  
>  		err = amdgpu_device_initialize(fd, &major, &minor, &device);
> @@ -1186,6 +1186,17 @@ igt_main
>  			process, sh_mem, const_num_of_tests, info[0].hw_ip_version_major,
>  			&monitor_child, &test_child);
>  	}
> +	//print expect error table for each test
> +	if(!argc)  {// --list-subtests arg is 0
> +		for (int i = 0; i < ARRAY_SIZE(ip_tests); i++)
> +			for (struct dynamic_test *it = &arr_err[0]; it->name; it++) {
> +				expect_error = ip_tests[i] == AMD_IP_COMPUTE ?
> +						it->result.compute_reset_result : it->result.gfx_reset_result;
> +				printf("test ip: %s,  test: %s,  expected error:%d \n",
> +					ip_tests[i] == AMD_IP_COMPUTE ? "COMPUTE":"GFX", it->name, expect_error);
> +			}
> +	}
> +
>  	for (int i = 0; i < ARRAY_SIZE(ip_tests); i++) {
>  		reset_rings_numbers(&ring_id_good, &ring_id_bad, &ring_id_job_good, &ring_id_job_bad);
>  		for (struct dynamic_test *it = &arr_err[0]; it->name; it++) {

  parent reply	other threads:[~2024-09-13 19:19 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-09-13 10:07 [PATCH i-g-t] tests/amdgpu: print expect error information Jesse.zhang@amd.com
2024-09-13 11:42 ` ✓ CI.xeBAT: success for " Patchwork
2024-09-13 12:04 ` ✗ Fi.CI.BAT: failure " Patchwork
2024-09-13 19:19 ` vitaly prosyak [this message]
2024-09-14  0:18 ` ✗ CI.xeFULL: " Patchwork

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7e28cbdf-5c00-4275-a9f8-8433509ce177@amd.com \
    --to=vprosyak@amd.com \
    --cc=alexander.deucher@amd.com \
    --cc=christian.koenig@amd.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=jesse.zhang@amd.com \
    --cc=kamil.konieczny@linux.intel.com \
    --cc=vitaly.prosyak@amd.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox