aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h
diff options
context:
space:
mode:
authorMonk Liu <Monk.Liu@amd.com>2017-03-21 18:48:45 +0800
committerAlex Deucher <alexander.deucher@amd.com>2017-03-29 23:55:38 -0400
commite09706f46ebecf3ae39996772c0ece12e91d8c45 (patch)
treeb73ae389eb1d2dc88cc338aa46d7ad6f80b9edf8 /drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h
parentdrm/amdgpu:virt_init_setting invoke is missed! (diff)
downloadlinux-dev-e09706f46ebecf3ae39996772c0ece12e91d8c45.tar.xz
linux-dev-e09706f46ebecf3ae39996772c0ece12e91d8c45.zip
drm/amdgpu:fix ring init sequence
ring->buf_mask need be set prior to ring_clear_ring invoke and fix ring_clear_ring as well which should use buf_mask instead of ptr_mask Signed-off-by: Monk Liu <Monk.Liu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h b/drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h
index 9bc453f1855c..63e56398ca9a 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h
@@ -195,7 +195,7 @@ void amdgpu_ring_fini(struct amdgpu_ring *ring);
static inline void amdgpu_ring_clear_ring(struct amdgpu_ring *ring)
{
int i = 0;
- while (i <= ring->ptr_mask)
+ while (i <= ring->buf_mask)
ring->ring[i++] = ring->funcs->nop;
}