[PATCH 3/3] drm/amdgpu: Increase soft recovery timeout to .5s
Christian König
christian.koenig at amd.com
Fri Mar 8 08:29:57 UTC 2024
Am 07.03.24 um 20:04 schrieb Joshua Ashton:
> Results in much more reliable soft recovery on
> Steam Deck.
Waiting 500ms for a locked up shader is way to long I think. We could
increase the 10ms to something like 20ms, but I really wouldn't go much
over that.
This here just kills shaders which are in an endless loop, when that
takes longer than 10-20ms we really have a hardware problem which needs
a full reset to resolve.
Regards,
Christian.
>
> Signed-off-by: Joshua Ashton <joshua at froggi.es>
>
> Cc: Friedrich Vock <friedrich.vock at gmx.de>
> Cc: Bas Nieuwenhuizen <bas at basnieuwenhuizen.nl>
> Cc: Christian König <christian.koenig at amd.com>
> Cc: André Almeida <andrealmeid at igalia.com>
> Cc: stable at vger.kernel.org
> ---
> drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c
> index 57c94901ed0a..be99db0e077e 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c
> @@ -448,7 +448,7 @@ bool amdgpu_ring_soft_recovery(struct amdgpu_ring *ring, unsigned int vmid,
> spin_unlock_irqrestore(fence->lock, flags);
>
> atomic_inc(&ring->adev->gpu_reset_counter);
> - deadline = ktime_add_us(ktime_get(), 10000);
> + deadline = ktime_add_ms(ktime_get(), 500);
> while (!dma_fence_is_signaled(fence) &&
> ktime_to_ns(ktime_sub(deadline, ktime_get())) > 0)
> ring->funcs->soft_recovery(ring, vmid);
More information about the amd-gfx
mailing list