Skip to content

Commit 5a67c31

Browse files
ChristianKoenigAMDalexdeucher
authored andcommitted
drm/amdgpu: enable GTT fallback handling for dGPUs only
That is just a waste of time on APUs. Closes: https://gitlab.freedesktop.org/drm/amd/-/issues/3704 Fixes: 216c128 ("drm/amdgpu: use GTT only as fallback for VRAM|GTT") Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]> (cherry picked from commit e8fc090) Cc: [email protected]
1 parent 79365ea commit 5a67c31

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

drivers/gpu/drm/amd/amdgpu/amdgpu_object.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,8 @@ void amdgpu_bo_placement_from_domain(struct amdgpu_bo *abo, u32 domain)
161161
* When GTT is just an alternative to VRAM make sure that we
162162
* only use it as fallback and still try to fill up VRAM first.
163163
*/
164-
if (domain & abo->preferred_domains & AMDGPU_GEM_DOMAIN_VRAM)
164+
if (domain & abo->preferred_domains & AMDGPU_GEM_DOMAIN_VRAM &&
165+
!(adev->flags & AMD_IS_APU))
165166
places[c].flags |= TTM_PL_FLAG_FALLBACK;
166167
c++;
167168
}

0 commit comments

Comments
 (0)