From acee19f998234c4aec88c5fab364780312ba17e9 Mon Sep 17 00:00:00 2001 From: Thadeu Lima de Souza Cascardo Date: Mon, 9 Mar 2026 15:49:52 -0300 Subject: [PATCH] drm/ttm: document that ttm_bo_swapout deals with pages MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Both the target parameter and return value of ttm_bo_swapout deal with pages, not bytes. Reported-by: Tvrtko Ursulin Signed-off-by: Thadeu Lima de Souza Cascardo Acked-by: Christian König Signed-off-by: Tvrtko Ursulin Link: https://lore.kernel.org/r/20260309-ttm_bo_swapout_doc-v1-1-eeb08176a00b@igalia.com --- drivers/gpu/drm/ttm/ttm_bo.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/ttm/ttm_bo.c b/drivers/gpu/drm/ttm/ttm_bo.c index 34ce53b4bdb9..a9024e7b34de 100644 --- a/drivers/gpu/drm/ttm/ttm_bo.c +++ b/drivers/gpu/drm/ttm/ttm_bo.c @@ -1208,9 +1208,9 @@ const struct ttm_lru_walk_ops ttm_swap_ops = { * @man: The resource manager whose resources / buffer objects are * goint to be swapped out. * @gfp_flags: The gfp flags used for shmem page allocations. - * @target: The desired number of bytes to swap out. + * @target: The desired number of pages to swap out. * - * Return: The number of bytes actually swapped out, or negative error code + * Return: The number of pages actually swapped out, or negative error code * on error. */ s64 ttm_bo_swapout(struct ttm_device *bdev, struct ttm_operation_ctx *ctx,