]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
drm/amdgpu: use dma_fence_get_status() for adapter reset
authorAlex Deucher <alexander.deucher@amd.com>
Fri, 12 Dec 2025 16:13:58 +0000 (11:13 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 5 Jan 2026 21:59:58 +0000 (16:59 -0500)
We need to check if the fence was signaled without an
error as the per queue resets may have signalled the fence
while attempting to reset the queue.

Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c

index 6378926f1aeb7166d64abbfb2ed8f4b6da4f5d5e..8f3ca5a30cc648820f546d80da78b14c3bca53cb 100644 (file)
@@ -6539,7 +6539,7 @@ int amdgpu_device_gpu_recover(struct amdgpu_device *adev,
         *
         * job->base holds a reference to parent fence
         */
-       if (job && dma_fence_is_signaled(&job->hw_fence->base)) {
+       if (job && (dma_fence_get_status(&job->hw_fence->base) > 0)) {
                job_signaled = true;
                dev_info(adev->dev, "Guilty job already signaled, skipping HW reset");
                goto skip_hw_reset;