Skip to content

Commit 6e3f451

Browse files
Tvrtko Ursulintursulin
authored andcommitted
drm/ttm: Fix ttm_pool_beneficial_order() return type
Fix a nasty copy and paste bug, where the incorrect boolean return type of the ttm_pool_beneficial_order() helper had a consequence of avoiding direct reclaim too eagerly for drivers which use this feature (currently amdgpu). Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@igalia.com> Fixes: 7e9c548 ("drm/ttm: Allow drivers to specify maximum beneficial TTM pool size") Cc: Christian König <christian.koenig@amd.com> Cc: Thadeu Lima de Souza Cascardo <cascardo@igalia.com> Cc: dri-devel@lists.freedesktop.org Cc: <stable@vger.kernel.org> # v6.19+ Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Tvrtko Ursulin <tursulin@ursulin.net> Link: https://lore.kernel.org/r/20260227124901.3177-1-tvrtko.ursulin@igalia.com
1 parent 36d9579 commit 6e3f451

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/gpu/drm/ttm/ttm_pool_internal.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ static inline bool ttm_pool_uses_dma32(struct ttm_pool *pool)
1717
return pool->alloc_flags & TTM_ALLOCATION_POOL_USE_DMA32;
1818
}
1919

20-
static inline bool ttm_pool_beneficial_order(struct ttm_pool *pool)
20+
static inline unsigned int ttm_pool_beneficial_order(struct ttm_pool *pool)
2121
{
2222
return pool->alloc_flags & 0xff;
2323
}

0 commit comments

Comments
 (0)