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

Configure Feed

Select the types of activity you want to include in your feed.

dma-buf: fix stale @lock references in struct dma_buf documentation

The kernel-doc comments for vmapping_counter and vmap_ptr in struct
dma_buf reference "@lock" as the protecting lock, but struct dma_buf
no longer has a "lock" member. The mutex was removed in favor of using
the dma_resv lock exclusively. The implementation correctly uses
dma_resv_assert_held(dmabuf->resv) in dma_buf_vmap() and
dma_buf_vunmap(), so update the documentation to reference @resv
instead.

Signed-off-by: gaoxiang17 <gaoxiang17@xiaomi.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Christian König <christian.koenig@amd.com>
Link: https://lore.kernel.org/r/20260415054101.535520-1-gxxa03070307@gmail.com

authored by

Xiang Gao and committed by
Christian König
0b13173d 2fc87d37

+2 -2
+2 -2
include/linux/dma-buf.h
··· 322 322 * @vmapping_counter: 323 323 * 324 324 * Used internally to refcnt the vmaps returned by dma_buf_vmap(). 325 - * Protected by @lock. 325 + * Protected by @resv. 326 326 */ 327 327 unsigned vmapping_counter; 328 328 329 329 /** 330 330 * @vmap_ptr: 331 - * The current vmap ptr if @vmapping_counter > 0. Protected by @lock. 331 + * The current vmap ptr if @vmapping_counter > 0. Protected by @resv. 332 332 */ 333 333 struct iosys_map vmap_ptr; 334 334