Commit cc7d8c79 authored by Monk Liu's avatar Monk Liu Committed by Alex Deucher

drm/amdgpu: clear RB at ring init

This help fix reloading driver hang issue of SDMA
ring.
Signed-off-by: default avatarMonk Liu <Monk.Liu@amd.com>
Reviewed-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Reviewed-by: default avatarChristian König <christian.koenig@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 5dd0775e
...@@ -310,6 +310,9 @@ int amdgpu_ring_init(struct amdgpu_device *adev, struct amdgpu_ring *ring, ...@@ -310,6 +310,9 @@ int amdgpu_ring_init(struct amdgpu_device *adev, struct amdgpu_ring *ring,
} }
r = amdgpu_bo_kmap(ring->ring_obj, r = amdgpu_bo_kmap(ring->ring_obj,
(void **)&ring->ring); (void **)&ring->ring);
memset((void *)ring->ring, 0, ring->ring_size);
amdgpu_bo_unreserve(ring->ring_obj); amdgpu_bo_unreserve(ring->ring_obj);
if (r) { if (r) {
dev_err(adev->dev, "(%d) ring map failed\n", r); dev_err(adev->dev, "(%d) ring map failed\n", 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