diff options
author | Marek Szyprowski <m.szyprowski@samsung.com> | 2011-12-21 10:55:33 -0500 |
---|---|---|
committer | Marek Szyprowski <m.szyprowski@samsung.com> | 2012-03-28 10:36:42 -0400 |
commit | 9adc537452e1e341cabd39a02d4788d3c510b0e2 (patch) | |
tree | 17911e3c2e58cf20759e001ce718c8514a6a4027 /include/linux | |
parent | 645ae3bce3e62541f8dc2701dde2a2791d842b6c (diff) |
common: dma-mapping: introduce mmap method
Introduce new generic mmap method with attributes argument.
This method lets drivers to create a userspace mapping for a DMA buffer
in generic, architecture independent way.
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Acked-by: Kyungmin Park <kyungmin.park@samsung.com>
Reviewed-by: Arnd Bergmann <arnd@arndb.de>
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/dma-mapping.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/dma-mapping.h b/include/linux/dma-mapping.h index 2fc413a873ea..b903a20867f7 100644 --- a/include/linux/dma-mapping.h +++ b/include/linux/dma-mapping.h | |||
@@ -15,6 +15,9 @@ struct dma_map_ops { | |||
15 | void (*free)(struct device *dev, size_t size, | 15 | void (*free)(struct device *dev, size_t size, |
16 | void *vaddr, dma_addr_t dma_handle, | 16 | void *vaddr, dma_addr_t dma_handle, |
17 | struct dma_attrs *attrs); | 17 | struct dma_attrs *attrs); |
18 | int (*mmap)(struct device *, struct vm_area_struct *, | ||
19 | void *, dma_addr_t, size_t, struct dma_attrs *attrs); | ||
20 | |||
18 | dma_addr_t (*map_page)(struct device *dev, struct page *page, | 21 | dma_addr_t (*map_page)(struct device *dev, struct page *page, |
19 | unsigned long offset, size_t size, | 22 | unsigned long offset, size_t size, |
20 | enum dma_data_direction dir, | 23 | enum dma_data_direction dir, |