summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c
diff options
context:
space:
mode:
authorChristian König <christian.koenig@amd.com>2018-03-01 11:01:52 +0100
committerAlex Deucher <alexander.deucher@amd.com>2018-03-05 15:37:12 -0500
commit57adc4cef617d7284ac7676e14533268e73e3699 (patch)
tree48f9789aa89591c04b96e4c2c2f663a51fc2aaad /drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c
parentc396ef9bf3172fd57e86df4529b11d563f9ff801 (diff)
downloadlinux-0-day-57adc4cef617d7284ac7676e14533268e73e3699.tar.gz
linux-0-day-57adc4cef617d7284ac7676e14533268e73e3699.tar.xz
drm/amdgpu: change amdgpu_ttm_set_active_vram_size
Instead of setting the active VRAM size directly provide a the info if we can use the buffer functions or not. Signed-off-by: Christian König <christian.koenig@amd.com> Acked-by: Chunming zhou <david1.zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c b/drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c
index 87c01d9587031..215743df09578 100644
--- a/drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c
@@ -426,7 +426,7 @@ static void sdma_v4_0_gfx_stop(struct amdgpu_device *adev)
if ((adev->mman.buffer_funcs_ring == sdma0) ||
(adev->mman.buffer_funcs_ring == sdma1))
- amdgpu_ttm_set_active_vram_size(adev, adev->gmc.visible_vram_size);
+ amdgpu_ttm_set_buffer_funcs_status(adev, false);
for (i = 0; i < adev->sdma.num_instances; i++) {
rb_cntl = RREG32(sdma_v4_0_get_reg_offset(adev, i, mmSDMA0_GFX_RB_CNTL));
@@ -668,7 +668,7 @@ static int sdma_v4_0_gfx_resume(struct amdgpu_device *adev)
}
if (adev->mman.buffer_funcs_ring == ring)
- amdgpu_ttm_set_active_vram_size(adev, adev->gmc.real_vram_size);
+ amdgpu_ttm_set_buffer_funcs_status(adev, true);
}