aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
diff options
context:
space:
mode:
authorChunming Zhou <david1.zhou@amd.com>2015-09-23 05:22:43 -0400
committerAlex Deucher <alexander.deucher@amd.com>2015-10-07 23:48:22 -0400
commit95d7918323be0090a1cc36f0ebdd1d3af88f2335 (patch)
tree2c6dd61dcace9efd5b8ccf09e0dcf7d68dc9e99a /drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
parenta2ef8a974931bd4a28e81a3de0a3813e97acfc30 (diff)
drm/amdgpu: add TOPDOWN flag to the whole vram
need to decrease visible vram usage by default. Signed-off-by: Chunming Zhou <david1.zhou@amd.com> Reviewed-by: monk.liu <monk.liu@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_object.c')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_object.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
index 1a7708f365f3..0d524384ff79 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
@@ -132,6 +132,8 @@ static void amdgpu_ttm_placement_init(struct amdgpu_device *adev,
132 placements[c].fpfn = 0; 132 placements[c].fpfn = 0;
133 placements[c++].flags = TTM_PL_FLAG_WC | TTM_PL_FLAG_UNCACHED | 133 placements[c++].flags = TTM_PL_FLAG_WC | TTM_PL_FLAG_UNCACHED |
134 TTM_PL_FLAG_VRAM; 134 TTM_PL_FLAG_VRAM;
135 if (!(flags & AMDGPU_GEM_CREATE_CPU_ACCESS_REQUIRED))
136 placements[c - 1].flags |= TTM_PL_FLAG_TOPDOWN;
135 } 137 }
136 138
137 if (domain & AMDGPU_GEM_DOMAIN_GTT) { 139 if (domain & AMDGPU_GEM_DOMAIN_GTT) {