diff options
author | Monk Liu <Monk.Liu@amd.com> | 2016-05-25 04:55:50 -0400 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2016-06-09 10:48:58 -0400 |
commit | d72f7c0685870aa7efda0a06f8ca160a94905031 (patch) | |
tree | 9c47362349765c008bf254277979c6e77283cd7f /drivers/gpu/drm | |
parent | 9a005bef5b5b5ceb78ff1138e6d6baf4bbeb8061 (diff) |
drm/amdgpu: init more register for sdma
This help fix reloading driver hang issue of SDMA
ring
Signed-off-by: Monk Liu <Monk.Liu@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm')
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/cik_sdma.c | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/sdma_v2_4.c | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c | 2 |
3 files changed, 6 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/cik_sdma.c b/drivers/gpu/drm/amd/amdgpu/cik_sdma.c index 518dca43b133..76f73ab9294e 100644 --- a/drivers/gpu/drm/amd/amdgpu/cik_sdma.c +++ b/drivers/gpu/drm/amd/amdgpu/cik_sdma.c | |||
@@ -419,6 +419,8 @@ static int cik_sdma_gfx_resume(struct amdgpu_device *adev) | |||
419 | /* Initialize the ring buffer's read and write pointers */ | 419 | /* Initialize the ring buffer's read and write pointers */ |
420 | WREG32(mmSDMA0_GFX_RB_RPTR + sdma_offsets[i], 0); | 420 | WREG32(mmSDMA0_GFX_RB_RPTR + sdma_offsets[i], 0); |
421 | WREG32(mmSDMA0_GFX_RB_WPTR + sdma_offsets[i], 0); | 421 | WREG32(mmSDMA0_GFX_RB_WPTR + sdma_offsets[i], 0); |
422 | WREG32(mmSDMA0_GFX_IB_RPTR + sdma_offsets[i], 0); | ||
423 | WREG32(mmSDMA0_GFX_IB_OFFSET + sdma_offsets[i], 0); | ||
422 | 424 | ||
423 | /* set the wb address whether it's enabled or not */ | 425 | /* set the wb address whether it's enabled or not */ |
424 | WREG32(mmSDMA0_GFX_RB_RPTR_ADDR_HI + sdma_offsets[i], | 426 | WREG32(mmSDMA0_GFX_RB_RPTR_ADDR_HI + sdma_offsets[i], |
diff --git a/drivers/gpu/drm/amd/amdgpu/sdma_v2_4.c b/drivers/gpu/drm/amd/amdgpu/sdma_v2_4.c index f4c3130d3fdb..e11a37416e19 100644 --- a/drivers/gpu/drm/amd/amdgpu/sdma_v2_4.c +++ b/drivers/gpu/drm/amd/amdgpu/sdma_v2_4.c | |||
@@ -461,6 +461,8 @@ static int sdma_v2_4_gfx_resume(struct amdgpu_device *adev) | |||
461 | /* Initialize the ring buffer's read and write pointers */ | 461 | /* Initialize the ring buffer's read and write pointers */ |
462 | WREG32(mmSDMA0_GFX_RB_RPTR + sdma_offsets[i], 0); | 462 | WREG32(mmSDMA0_GFX_RB_RPTR + sdma_offsets[i], 0); |
463 | WREG32(mmSDMA0_GFX_RB_WPTR + sdma_offsets[i], 0); | 463 | WREG32(mmSDMA0_GFX_RB_WPTR + sdma_offsets[i], 0); |
464 | WREG32(mmSDMA0_GFX_IB_RPTR + sdma_offsets[i], 0); | ||
465 | WREG32(mmSDMA0_GFX_IB_OFFSET + sdma_offsets[i], 0); | ||
464 | 466 | ||
465 | /* set the wb address whether it's enabled or not */ | 467 | /* set the wb address whether it's enabled or not */ |
466 | WREG32(mmSDMA0_GFX_RB_RPTR_ADDR_HI + sdma_offsets[i], | 468 | WREG32(mmSDMA0_GFX_RB_RPTR_ADDR_HI + sdma_offsets[i], |
diff --git a/drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c b/drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c index 31d99b0010f7..585d8fe22bae 100644 --- a/drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c +++ b/drivers/gpu/drm/amd/amdgpu/sdma_v3_0.c | |||
@@ -672,6 +672,8 @@ static int sdma_v3_0_gfx_resume(struct amdgpu_device *adev) | |||
672 | /* Initialize the ring buffer's read and write pointers */ | 672 | /* Initialize the ring buffer's read and write pointers */ |
673 | WREG32(mmSDMA0_GFX_RB_RPTR + sdma_offsets[i], 0); | 673 | WREG32(mmSDMA0_GFX_RB_RPTR + sdma_offsets[i], 0); |
674 | WREG32(mmSDMA0_GFX_RB_WPTR + sdma_offsets[i], 0); | 674 | WREG32(mmSDMA0_GFX_RB_WPTR + sdma_offsets[i], 0); |
675 | WREG32(mmSDMA0_GFX_IB_RPTR + sdma_offsets[i], 0); | ||
676 | WREG32(mmSDMA0_GFX_IB_OFFSET + sdma_offsets[i], 0); | ||
675 | 677 | ||
676 | /* set the wb address whether it's enabled or not */ | 678 | /* set the wb address whether it's enabled or not */ |
677 | WREG32(mmSDMA0_GFX_RB_RPTR_ADDR_HI + sdma_offsets[i], | 679 | WREG32(mmSDMA0_GFX_RB_RPTR_ADDR_HI + sdma_offsets[i], |