drm/ttm: Should to return the evict error
Subsystems (3)
PATCH v3 1/1 drm/ttm: Should to return the evict error
For the evict fail case, the evict error should be returned.
v2: Consider ENOENT case.
v3: Abort directly when the eviction failed for some reason (except for -ENOENT)
and not wait for the move to finish
--- drivers/gpu/drm/ttm/ttm_resource.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/gpu/drm/ttm/ttm_resource.c +3 -0
@@ -558,6 +558,9 @@ int ttm_resource_manager_evict_all(struct ttm_device *bdev,cond_resched (); }while (!ret); +if (ret != -ENOENT ) +return ret; +spin_lock (&man->move_lock); fence =dma_fence_get (man->move);spin_unlock (&man->move_lock);
Signature · 1 line
2.34.1
[AMD Official Use Only - AMD Internal Distribution Only]
Sorry, send the wrong patch, please ignore this.
Emily Deng
Best Wishes
Quoted 35 lines
-----Original Message-----
From: Emily Deng <[email protected]>
Sent: Tuesday, June 3, 2025 5:10 PM
To: [email protected]
Cc: Deng, Emily <[email protected]>
Subject: [PATCH v3] drm/ttm: Should to return the evict errorFor the evict fail case, the evict error should be returned.
v2: Consider ENOENT case.
v3: Abort directly when the eviction failed for some reason (except for
-ENOENT) and not wait for the move to finishSigned-off-by Emily Deng <[email protected]>---
drivers/gpu/drm/ttm/ttm_resource.c| 3 +++1 file changed, 3 insertions(+)drivers/gpu/drm/ttm/ttm_resource.c +3
-1@@ -558,6 +558,9 @@ int ttm_resource_manager_evict_all(struct ttm_device *bdev,cond_resched (); }while (!ret); +if (ret != -ENOENT ) +return ret; +spin_lock (&man->move_lock); fence =dma_fence_get (man->move);spin_unlock (&man->move_lock); --2.34.1