Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drm/ttm: Fix @alloc_flags description

Stephen Rothwell reports htmldocs warnings when merging drm-misc tree:

Documentation/gpu/drm-mm:40: include/drm/ttm/ttm_device.h:225: ERROR: Unknown target name: "ttm_allocation". [docutils]
Documentation/gpu/drm-mm:43: drivers/gpu/drm/ttm/ttm_device.c:202: ERROR: Unknown target name: "ttm_allocation". [docutils]
Documentation/gpu/drm-mm:73: include/drm/ttm/ttm_pool.h:68: ERROR: Unknown target name: "ttm_allocation_pool". [docutils]
Documentation/gpu/drm-mm:76: drivers/gpu/drm/ttm/ttm_pool.c:1070: ERROR: Unknown target name: "ttm_allocation_pool". [docutils]

Fix these by adding missing wildcard on TTM_ALLOCATION_* and
TTM_ALLOCATION_POOL_* in @alloc_flags description.

Fixes: 0af5b6a8f8dd ("drm/ttm: Replace multiple booleans with flags in pool init")
Fixes: 77e19f8d3297 ("drm/ttm: Replace multiple booleans with flags in device init")
Fixes: 402b3a865090 ("drm/ttm: Add an allocation flag to propagate -ENOSPC on OOM")
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Closes: https://lore.kernel.org/linux-next/20251105161838.55b962a3@canb.auug.org.au/
Signed-off-by: Bagas Sanjaya <bagasdotme@gmail.com>
Acked-by: Tvrtko Ursulin <tvrtko.ursulin@igalia.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Tvrtko Ursulin <tursulin@ursulin.net>
Link: https://lore.kernel.org/r/20251106005217.14026-1-bagasdotme@gmail.com

authored by

Bagas Sanjaya and committed by
Tvrtko Ursulin
3ca8b266 b6fa6100

+4 -4
+1 -1
drivers/gpu/drm/ttm/ttm_device.c
··· 199 199 * @dev: The core kernel device pointer for DMA mappings and allocations. 200 200 * @mapping: The address space to use for this bo. 201 201 * @vma_manager: A pointer to a vma manager. 202 - * @alloc_flags: TTM_ALLOCATION_ flags. 202 + * @alloc_flags: TTM_ALLOCATION_* flags. 203 203 * 204 204 * Initializes a struct ttm_device: 205 205 * Returns:
+1 -1
drivers/gpu/drm/ttm/ttm_pool.c
··· 1067 1067 * @pool: the pool to initialize 1068 1068 * @dev: device for DMA allocations and mappings 1069 1069 * @nid: NUMA node to use for allocations 1070 - * @alloc_flags: TTM_ALLOCATION_POOL_ flags 1070 + * @alloc_flags: TTM_ALLOCATION_POOL_* flags 1071 1071 * 1072 1072 * Initialize the pool and its pool types. 1073 1073 */
+1 -1
include/drm/ttm/ttm_device.h
··· 221 221 struct list_head device_list; 222 222 223 223 /** 224 - * @alloc_flags: TTM_ALLOCATION_ flags. 224 + * @alloc_flags: TTM_ALLOCATION_* flags. 225 225 */ 226 226 unsigned int alloc_flags; 227 227
+1 -1
include/drm/ttm/ttm_pool.h
··· 64 64 * 65 65 * @dev: the device we allocate pages for 66 66 * @nid: which numa node to use 67 - * @alloc_flags: TTM_ALLOCATION_POOL_ flags 67 + * @alloc_flags: TTM_ALLOCATION_POOL_* flags 68 68 * @caching: pools for each caching/order 69 69 */ 70 70 struct ttm_pool {