projects/linux·commit b25b086d

dma-buf: add initial vmap documentation

b25b086d · Dave Airlie <[email protected]> · 2012-05-22 13:34:38 +01:00

Signed-off-by: Dave Airlie <[email protected]>
Signed-off-by: Sumit Semwal <[email protected]>
Commit
b25b086d23eb852bf3cfdeb60409b4967ebb3c0c
Parents
12c4727e

Changes

1 files changed · +11 −0

FileStatusAddDelContent
Documentation/dma-buf-sharing.txtmodified+11−0View file

Documentation/dma-buf-sharing.txt

View file
diff --git a/Documentation/dma-buf-sharing.txt b/Documentation/dma-buf-sharing.txt
index 5ff4d2b..ad86fb8 100644
--- a/Documentation/dma-buf-sharing.txt
+++ b/Documentation/dma-buf-sharing.txt
@@ -293,6 +293,17 @@ Access to a dma_buf from the kernel context involves three steps:
Note that these calls need to always succeed. The exporter needs to complete
any preparations that might fail in begin_cpu_access.
+ For some cases the overhead of kmap can be too high, a vmap interface
+ is introduced. This interface should be used very carefully, as vmalloc
+ space is a limited resources on many architectures.
+
+ Interfaces:
+ void *dma_buf_vmap(struct dma_buf *dmabuf)
+ void dma_buf_vunmap(struct dma_buf *dmabuf, void *vaddr)
+
+ The vmap call can fail if there is no vmap support in the exporter, or if it
+ runs out of vmalloc space. Fallback to kmap should be implemented.
+
3. Finish access
When the importer is done accessing the range specified in begin_cpu_access,