Skip to contentSkip to conversation

drm/amdgpu: tolerate allocating GTT bo with dcc flag

PATCH In review Min, Frank 2 participants 2 messages Jun 6, 2024 1 message not in the archive

Subsystems (2)
lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

Min, Frank

author
#1 lore raw

PATCH 1/1 drm/amdgpu: tolerate allocating GTT bo with dcc flag

[AMD Official Use Only - AMD Internal Distribution Only]

From: Frank Min <[email protected]>

Do not return failure for allocating GTT bo with dcc flag on gfx12. This will improve compatibility for UMD.

---
 drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c | 5 -----
 1 file changed, 5 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c +0 -5
index 9041c63cabb0..58186de61403 100644
@@ -409,11 +409,6 @@ int amdgpu_gem_create_ioctl(struct drm_device *dev, void *data,
        if (args->in.domains & ~AMDGPU_GEM_DOMAIN_MASK)
                return -EINVAL;
 
-       if ((flags & AMDGPU_GEM_CREATE_GFX12_DCC) &&
-           ((amdgpu_ip_version(adev, GC_HWIP, 0) < IP_VERSION(12, 0, 0)) ||
-            !(args->in.domains & AMDGPU_GEM_DOMAIN_VRAM)))
-               return -EINVAL;
-
        if (!amdgpu_is_tmz(adev) && (flags & AMDGPU_GEM_CREATE_ENCRYPTED)) {
                DRM_NOTE_ONCE("Cannot allocate secure buffer since TMZ is disabled\n");
                return -EINVAL;

--
2.34.1

Reviewed-by Reviewed-by Christian König on v1 1/1
#2 lore raw

[AMD Official Use Only - AMD Internal Distribution Only]

Regards,
Hawking

-----Original Message-----
From: Min, Frank <[email protected]>
Sent: Thursday, June 6, 2024 16:11
To: [email protected]
Cc: Koenig, Christian <[email protected]>; Deucher, Alexander <[email protected]>; Zhang, Hawking <[email protected]>
Subject: [PATCH] drm/amdgpu: tolerate allocating GTT bo with dcc flag

[AMD Official Use Only - AMD Internal Distribution Only]

From: Frank Min <[email protected]>

Do not return failure for allocating GTT bo with dcc flag on gfx12. This will improve compatibility for UMD.

---
 drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c | 5 -----
 1 file changed, 5 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c +0 -5
index 9041c63cabb0..58186de61403 100644
@@ -409,11 +409,6 @@ int amdgpu_gem_create_ioctl(struct drm_device *dev, void *data,
        if (args->in.domains & ~AMDGPU_GEM_DOMAIN_MASK)
                return -EINVAL;
 
-       if ((flags & AMDGPU_GEM_CREATE_GFX12_DCC) &&
-           ((amdgpu_ip_version(adev, GC_HWIP, 0) < IP_VERSION(12, 0, 0)) ||
-            !(args->in.domains & AMDGPU_GEM_DOMAIN_VRAM)))
-               return -EINVAL;
-
        if (!amdgpu_is_tmz(adev) && (flags & AMDGPU_GEM_CREATE_ENCRYPTED)) {
                DRM_NOTE_ONCE("Cannot allocate secure buffer since TMZ is disabled\n");
                return -EINVAL;

--
2.34.1