From: xinhui pan <xinhui.pan@amd.com>
To: <amd-gfx@lists.freedesktop.org>
Cc: <alexander.deucher@amd.com>, <christian.koenig@amd.com>,
<chenli@uniontech.com>, <dri-devel@lists.freedesktop.org>,
xinhui pan <xinhui.pan@amd.com>
Subject: [PATCH v2 2/2] drm/amdpgu: Use VRAM domain in UVD IB test
Date: Mon, 6 Sep 2021 09:12:10 +0800 [thread overview]
Message-ID: <20210906011210.80327-3-xinhui.pan@amd.com> (raw)
In-Reply-To: <20210906011210.80327-1-xinhui.pan@amd.com>
Like vce/vcn does, visible VRAM is OK for ib test.
While commit a11d9ff3ebe0 ("drm/amdgpu: use GTT for
uvd_get_create/destory_msg") says VRAM is not mapped correctly in his
platform which is likely an arm64.
So lets change back to use VRAM on x86_64 platform.
Signed-off-by: xinhui pan <xinhui.pan@amd.com>
---
drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c
index d451c359606a..e4b75f33ccc8 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c
@@ -1178,7 +1178,11 @@ int amdgpu_uvd_get_create_msg(struct amdgpu_ring *ring, uint32_t handle,
int r, i;
r = amdgpu_bo_create_reserved(adev, 1024, PAGE_SIZE,
+#ifdef CONFIG_X86_64
+ AMDGPU_GEM_DOMAIN_VRAM,
+#else
AMDGPU_GEM_DOMAIN_GTT,
+#endif
&bo, NULL, (void **)&msg);
if (r)
return r;
@@ -1210,7 +1214,11 @@ int amdgpu_uvd_get_destroy_msg(struct amdgpu_ring *ring, uint32_t handle,
int r, i;
r = amdgpu_bo_create_reserved(adev, 1024, PAGE_SIZE,
+#ifdef CONFIG_X86_64
+ AMDGPU_GEM_DOMAIN_VRAM,
+#else
AMDGPU_GEM_DOMAIN_GTT,
+#endif
&bo, NULL, (void **)&msg);
if (r)
return r;
--
2.25.1
next prev parent reply other threads:[~2021-09-06 1:12 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-06 1:12 [PATCH v2 0/2] Fix a hung during memory pressure test xinhui pan
2021-09-06 1:12 ` [PATCH v2 1/2] drm/ttm: Fix a deadlock if the target BO is not idle during swap xinhui pan
2021-09-06 11:26 ` Christian König
2021-09-07 1:52 ` Pan, Xinhui
2021-09-06 1:12 ` xinhui pan [this message]
2021-09-06 9:01 ` [PATCH v2 2/2] drm/amdpgu: Use VRAM domain in UVD IB test Christian König
2021-09-06 9:04 ` [PATCH v2 0/2] Fix a hung during memory pressure test Christian König
2021-09-06 10:16 ` Pan, Xinhui
2021-09-06 11:04 ` Christian König
-- strict thread matches above, loose matches on Subject: below --
2021-09-06 1:10 [PATCH v2 2/2] drm/amdpgu: Use VRAM domain in UVD IB test Pan, Xinhui
2021-09-06 2:55 ` Wang, Kevin(Yang)
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=20210906011210.80327-3-xinhui.pan@amd.com \
--to=xinhui.pan@amd.com \
--cc=alexander.deucher@amd.com \
--cc=amd-gfx@lists.freedesktop.org \
--cc=chenli@uniontech.com \
--cc=christian.koenig@amd.com \
--cc=dri-devel@lists.freedesktop.org \
/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