diff options
author | Alex Deucher <alexander.deucher@amd.com> | 2022-10-06 15:31:40 -0400 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2022-10-10 17:32:56 -0400 |
commit | 571c053658926df3321633b7133f574d3e656c81 (patch) | |
tree | b2f933496c62c4e923917be9746a234f9c76aad9 /drivers/gpu/drm/amd/amdgpu/si_dma.c | |
parent | e5da651985be20616a9e0662032e0ea2ee4dd468 (diff) | |
download | linux-571c053658926df3321633b7133f574d3e656c81.tar.gz linux-571c053658926df3321633b7133f574d3e656c81.tar.bz2 linux-571c053658926df3321633b7133f574d3e656c81.zip |
drm/amdgpu: switch sdma buffer function tear down to a helper
Switch all of the SDMA implementations to use the helper to
tear down the ttm buffer manager.
Tested-by: Bokun Zhang <Bokun.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/si_dma.c')
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/si_dma.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/si_dma.c b/drivers/gpu/drm/amd/amdgpu/si_dma.c index f675111ace20..4d5e718540aa 100644 --- a/drivers/gpu/drm/amd/amdgpu/si_dma.c +++ b/drivers/gpu/drm/amd/amdgpu/si_dma.c @@ -116,15 +116,14 @@ static void si_dma_stop(struct amdgpu_device *adev) u32 rb_cntl; unsigned i; + amdgpu_sdma_unset_buffer_funcs_helper(adev); + for (i = 0; i < adev->sdma.num_instances; i++) { ring = &adev->sdma.instance[i].ring; /* dma0 */ rb_cntl = RREG32(DMA_RB_CNTL + sdma_offsets[i]); rb_cntl &= ~DMA_RB_ENABLE; WREG32(DMA_RB_CNTL + sdma_offsets[i], rb_cntl); - - if (adev->mman.buffer_funcs_ring == ring) - amdgpu_ttm_set_buffer_funcs_status(adev, false); } } |