aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/base/dma-buf.c9
-rw-r--r--include/linux/dma-buf.h3
2 files changed, 8 insertions, 4 deletions
diff --git a/drivers/base/dma-buf.c b/drivers/base/dma-buf.c
index d43d80256fda..20258e179211 100644
--- a/drivers/base/dma-buf.c
+++ b/drivers/base/dma-buf.c
@@ -429,7 +429,7 @@ EXPORT_SYMBOL_GPL(dma_buf_kunmap);
429 429
430/** 430/**
431 * dma_buf_mmap - Setup up a userspace mmap with the given vma 431 * dma_buf_mmap - Setup up a userspace mmap with the given vma
432 * @dma_buf: [in] buffer that should back the vma 432 * @dmabuf: [in] buffer that should back the vma
433 * @vma: [in] vma for the mmap 433 * @vma: [in] vma for the mmap
434 * @pgoff: [in] offset in pages where this mmap should start within the 434 * @pgoff: [in] offset in pages where this mmap should start within the
435 * dma-buf buffer. 435 * dma-buf buffer.
@@ -470,8 +470,9 @@ int dma_buf_mmap(struct dma_buf *dmabuf, struct vm_area_struct *vma,
470EXPORT_SYMBOL_GPL(dma_buf_mmap); 470EXPORT_SYMBOL_GPL(dma_buf_mmap);
471 471
472/** 472/**
473 * dma_buf_vmap - Create virtual mapping for the buffer object into kernel address space. Same restrictions as for vmap and friends apply. 473 * dma_buf_vmap - Create virtual mapping for the buffer object into kernel
474 * @dma_buf: [in] buffer to vmap 474 * address space. Same restrictions as for vmap and friends apply.
475 * @dmabuf: [in] buffer to vmap
475 * 476 *
476 * This call may fail due to lack of virtual mapping address space. 477 * This call may fail due to lack of virtual mapping address space.
477 * These calls are optional in drivers. The intended use for them 478 * These calls are optional in drivers. The intended use for them
@@ -491,7 +492,7 @@ EXPORT_SYMBOL_GPL(dma_buf_vmap);
491 492
492/** 493/**
493 * dma_buf_vunmap - Unmap a vmap obtained by dma_buf_vmap. 494 * dma_buf_vunmap - Unmap a vmap obtained by dma_buf_vmap.
494 * @dma_buf: [in] buffer to vmap 495 * @dmabuf: [in] buffer to vunmap
495 */ 496 */
496void dma_buf_vunmap(struct dma_buf *dmabuf, void *vaddr) 497void dma_buf_vunmap(struct dma_buf *dmabuf, void *vaddr)
497{ 498{
diff --git a/include/linux/dma-buf.h b/include/linux/dma-buf.h
index a02b1ff6488e..eb48f3816df9 100644
--- a/include/linux/dma-buf.h
+++ b/include/linux/dma-buf.h
@@ -65,6 +65,9 @@ struct dma_buf_attachment;
65 * mapping needs to be coherent - if the exporter doesn't directly 65 * mapping needs to be coherent - if the exporter doesn't directly
66 * support this, it needs to fake coherency by shooting down any ptes 66 * support this, it needs to fake coherency by shooting down any ptes
67 * when transitioning away from the cpu domain. 67 * when transitioning away from the cpu domain.
68 * @vmap: [optional] creates a virtual mapping for the buffer into kernel
69 * address space. Same restrictions as for vmap and friends apply.
70 * @vunmap: [optional] unmaps a vmap from the buffer
68 */ 71 */
69struct dma_buf_ops { 72struct dma_buf_ops {
70 int (*attach)(struct dma_buf *, struct device *, 73 int (*attach)(struct dma_buf *, struct device *,