summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorHawking Zhang <Hawking.Zhang@amd.com>2022-02-12 14:56:01 +0800
committerLikun Gao <gaolikunglk@gmail.com>2022-08-15 06:10:15 +0000
commit176e6ce6f3504b9cf5ce6a2a8b2e55cb201b986d (patch)
treed121586ddbcc0d4364da3260286551b7cdf6787f /tests
parent98794e2a0d537f3376970918bf955361191720c7 (diff)
downloaddrm-176e6ce6f3504b9cf5ce6a2a8b2e55cb201b986d.tar.gz
tests/amdgpu: skip gfx CE subtest in gfx11
CE is not available in gfx11 Signed-off-by: Hawking Zhang <Hawking.Zhang@amd.com> Reviewed-by: Likun Gao <Likun.Gao@amd.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/amdgpu/basic_tests.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/tests/amdgpu/basic_tests.c b/tests/amdgpu/basic_tests.c
index 688260d9..e4914737 100644
--- a/tests/amdgpu/basic_tests.c
+++ b/tests/amdgpu/basic_tests.c
@@ -857,6 +857,13 @@ static void amdgpu_command_submission_gfx_separate_ibs(void)
amdgpu_bo_list_handle bo_list;
amdgpu_va_handle va_handle, va_handle_ce;
int r, i = 0;
+ struct drm_amdgpu_info_hw_ip info;
+
+ r = amdgpu_query_hw_ip_info(device_handle, AMDGPU_HW_IP_GFX, 0, &info);
+ CU_ASSERT_EQUAL(r, 0);
+
+ if (info.hw_ip_version_major >= 11)
+ return;
r = amdgpu_cs_ctx_create(device_handle, &context_handle);
CU_ASSERT_EQUAL(r, 0);
@@ -948,6 +955,13 @@ static void amdgpu_command_submission_gfx_shared_ib(void)
amdgpu_bo_list_handle bo_list;
amdgpu_va_handle va_handle;
int r, i = 0;
+ struct drm_amdgpu_info_hw_ip info;
+
+ r = amdgpu_query_hw_ip_info(device_handle, AMDGPU_HW_IP_GFX, 0, &info);
+ CU_ASSERT_EQUAL(r, 0);
+
+ if (info.hw_ip_version_major >= 11)
+ return;
r = amdgpu_cs_ctx_create(device_handle, &context_handle);
CU_ASSERT_EQUAL(r, 0);
@@ -2070,6 +2084,13 @@ static void amdgpu_command_submission_multi_fence_wait_all(bool wait_all)
amdgpu_va_handle va_handle, va_handle_ce;
int r;
int i = 0, ib_cs_num = 2;
+ struct drm_amdgpu_info_hw_ip info;
+
+ r = amdgpu_query_hw_ip_info(device_handle, AMDGPU_HW_IP_GFX, 0, &info);
+ CU_ASSERT_EQUAL(r, 0);
+
+ if (info.hw_ip_version_major >= 11)
+ return;
r = amdgpu_cs_ctx_create(device_handle, &context_handle);
CU_ASSERT_EQUAL(r, 0);