Commit d423f551 authored by Christian König's avatar Christian König Committed by Alex Deucher

drm/amdgpu: nuke the ih reentrant lock

Interrupts on are non-reentrant on linux. This is just an ancient
leftover from radeon where irq processing was kicked of from different
places.
Signed-off-by: default avatarChristian König <christian.koenig@amd.com>
Reviewed-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 7816e4a9
...@@ -3284,7 +3284,6 @@ int amdgpu_device_init(struct amdgpu_device *adev, ...@@ -3284,7 +3284,6 @@ int amdgpu_device_init(struct amdgpu_device *adev,
/* mutex initialization are all done here so we /* mutex initialization are all done here so we
* can recall function without having locking issues */ * can recall function without having locking issues */
atomic_set(&adev->irq.ih.lock, 0);
mutex_init(&adev->firmware.mutex); mutex_init(&adev->firmware.mutex);
mutex_init(&adev->pm.mutex); mutex_init(&adev->pm.mutex);
mutex_init(&adev->gfx.gpu_clock_mutex); mutex_init(&adev->gfx.gpu_clock_mutex);
......
...@@ -228,10 +228,6 @@ int amdgpu_ih_process(struct amdgpu_device *adev, struct amdgpu_ih_ring *ih) ...@@ -228,10 +228,6 @@ int amdgpu_ih_process(struct amdgpu_device *adev, struct amdgpu_ih_ring *ih)
wptr = amdgpu_ih_get_wptr(adev, ih); wptr = amdgpu_ih_get_wptr(adev, ih);
restart_ih: restart_ih:
/* is somebody else already processing irqs? */
if (atomic_xchg(&ih->lock, 1))
return IRQ_NONE;
DRM_DEBUG("%s: rptr %d, wptr %d\n", __func__, ih->rptr, wptr); DRM_DEBUG("%s: rptr %d, wptr %d\n", __func__, ih->rptr, wptr);
/* Order reading of wptr vs. reading of IH ring data */ /* Order reading of wptr vs. reading of IH ring data */
...@@ -244,7 +240,6 @@ int amdgpu_ih_process(struct amdgpu_device *adev, struct amdgpu_ih_ring *ih) ...@@ -244,7 +240,6 @@ int amdgpu_ih_process(struct amdgpu_device *adev, struct amdgpu_ih_ring *ih)
amdgpu_ih_set_rptr(adev, ih); amdgpu_ih_set_rptr(adev, ih);
wake_up_all(&ih->wait_process); wake_up_all(&ih->wait_process);
atomic_set(&ih->lock, 0);
/* make sure wptr hasn't changed while processing */ /* make sure wptr hasn't changed while processing */
wptr = amdgpu_ih_get_wptr(adev, ih); wptr = amdgpu_ih_get_wptr(adev, ih);
......
...@@ -64,7 +64,6 @@ struct amdgpu_ih_ring { ...@@ -64,7 +64,6 @@ struct amdgpu_ih_ring {
bool enabled; bool enabled;
unsigned rptr; unsigned rptr;
atomic_t lock;
struct amdgpu_ih_regs ih_regs; struct amdgpu_ih_regs ih_regs;
/* For waiting on IH processing at checkpoint. */ /* For waiting on IH processing at checkpoint. */
......
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