drm/amdgpu/gfx9: reset cleanups
Subsystems (2)
Alex Deucher
maintainerPATCH 1/3 drm/amdgpu/gfx9: reset cleanups
Move the KIQ ring test into the kiq lock, add
the missing ring_commit.
Signed-off-by Alex Deucher <[email protected]>
--- drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-)
drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c +3 -6
@@ -7178,10 +7178,8 @@ static int gfx_v9_0_reset_kgq(struct amdgpu_ring *ring, unsigned int vmid)gfx_v9_0_ring_emit_wreg (kiq_ring,SOC15_REG_OFFSET (GC ,0 , mmCP_VMID_RESET), tmp);amdgpu_ring_commit (kiq_ring); - -spin_unlock_irqrestore (&kiq->ring_lock, flags); - r =amdgpu_ring_test_ring (kiq_ring); +spin_unlock_irqrestore (&kiq->ring_lock, flags);if (r)return r;
@@ -7193,6 +7191,7 @@ static int gfx_v9_0_reset_kgq(struct amdgpu_ring *ring, unsigned int vmid) SOC15_REG_OFFSET(GC, 0, mmCP_VMID_RESET), 0, 0xffff);gfx_v9_0_ring_emit_wreg (ring,SOC15_REG_OFFSET (GC ,0 , mmCP_VMID_RESET),0 ); +amdgpu_ring_commit (ring);return amdgpu_ring_test_ring (ring); }
@@ -7222,10 +7221,8 @@ static int gfx_v9_0_reset_kcq(struct amdgpu_ring *ring, kiq->pmf->kiq_unmap_queues (kiq_ring, ring,RESET_QUEUES ,0 ,0 );amdgpu_ring_commit (kiq_ring); - -spin_unlock_irqrestore (&kiq->ring_lock, flags); - r =amdgpu_ring_test_ring (kiq_ring); +spin_unlock_irqrestore (&kiq->ring_lock, flags);if (r)return r;
Signature · 1 line
2.49.0
Alex Deucher
maintainerPATCH 2/3 drm/amdgpu/gfx8: reset cleanups
Move the KIQ ring test into the kiq lock, add
the missing ring_commit.
Signed-off-by Alex Deucher <[email protected]>
--- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c +2 -3
@@ -6868,10 +6868,8 @@ static int gfx_v8_0_reset_kgq(struct amdgpu_ring *ring, unsigned int vmid) tmp =REG_SET_FIELD (0 ,CP_VMID_RESET ,RESET_REQUEST ,1 << vmid);gfx_v8_0_ring_emit_wreg (kiq_ring, mmCP_VMID_RESET, tmp);amdgpu_ring_commit (kiq_ring); - -spin_unlock_irqrestore (&kiq->ring_lock, flags); - r =amdgpu_ring_test_ring (kiq_ring); +spin_unlock_irqrestore (&kiq->ring_lock, flags);if (r)return r;
@@ -6881,6 +6879,7 @@ static int gfx_v8_0_reset_kgq(struct amdgpu_ring *ring, unsigned int vmid) ring->fence_drv.sync_seq, AMDGPU_FENCE_FLAG_EXEC);gfx_v8_0_ring_emit_reg_wait (ring, mmCP_VMID_RESET,0 ,0xffff );gfx_v8_0_ring_emit_wreg (ring, mmCP_VMID_RESET,0 ); +amdgpu_ring_commit (ring);return amdgpu_ring_test_ring (ring); }
Signature · 1 line
2.49.0
Alex Deucher
maintainerPATCH 3/3 drm/amdgpu/gfx7: reset cleanups
In reply to Alex DeucherMove the KIQ ring test into the kiq lock, add
the missing ring_commit.
Signed-off-by Alex Deucher <[email protected]>
--- drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c +2 -3
@@ -4937,10 +4937,8 @@ static int gfx_v7_0_reset_kgq(struct amdgpu_ring *ring, unsigned int vmid) tmp =REG_SET_FIELD (0 ,CP_VMID_RESET ,RESET_REQUEST ,1 << vmid);gfx_v7_0_ring_emit_wreg (kiq_ring, mmCP_VMID_RESET, tmp);amdgpu_ring_commit (kiq_ring); - -spin_unlock_irqrestore (&kiq->ring_lock, flags); - r =amdgpu_ring_test_ring (kiq_ring); +spin_unlock_irqrestore (&kiq->ring_lock, flags);if (r)return r;
@@ -4950,6 +4948,7 @@ static int gfx_v7_0_reset_kgq(struct amdgpu_ring *ring, unsigned int vmid) ring->fence_drv.sync_seq, AMDGPU_FENCE_FLAG_EXEC);gfx_v7_0_ring_emit_reg_wait (ring, mmCP_VMID_RESET,0 ,0xffff );gfx_v7_0_ring_emit_wreg (ring, mmCP_VMID_RESET,0 ); +amdgpu_ring_commit (ring);return amdgpu_ring_test_ring (ring); }
Signature · 1 line
2.49.0