Commit 70a9c6b9 authored by Christian König's avatar Christian König Committed by Alex Deucher

drm/amdgpu: fix placement flags in amdgpu_ttm_bind

Otherwise we lose the NO_EVICT flag and can try to evict pinned BOs.
Signed-off-by: default avatarChristian König <christian.koenig@amd.com>
Reviewed-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 481c2e94
...@@ -819,7 +819,7 @@ int amdgpu_ttm_bind(struct ttm_buffer_object *bo, struct ttm_mem_reg *bo_mem) ...@@ -819,7 +819,7 @@ int amdgpu_ttm_bind(struct ttm_buffer_object *bo, struct ttm_mem_reg *bo_mem)
placement.busy_placement = &placements; placement.busy_placement = &placements;
placements.fpfn = 0; placements.fpfn = 0;
placements.lpfn = adev->mc.gart_size >> PAGE_SHIFT; placements.lpfn = adev->mc.gart_size >> PAGE_SHIFT;
placements.flags = TTM_PL_MASK_CACHING | TTM_PL_FLAG_TT; placements.flags = bo->mem.placement | TTM_PL_FLAG_TT;
r = ttm_bo_mem_space(bo, &placement, &tmp, true, false); r = ttm_bo_mem_space(bo, &placement, &tmp, true, false);
if (unlikely(r)) if (unlikely(r))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment