mirror of
https://github.com/torvalds/linux.git
synced 2026-10-07 22:37:45 -04:00
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 <[email protected]> Acked-by: Kyungmin Park <[email protected]> Reviewed-by: Arnd Bergmann <[email protected]>
This commit is contained in:
1 parent
645ae3bce3
commit
9adc537452
1 file changed
+3
@@ -15,6 +15,9 @@ struct dma_map_ops {
|
||||
void (*free)(struct device *dev, size_t size,
|
||||
void *vaddr, dma_addr_t dma_handle,
|
||||
struct dma_attrs *attrs);
|
||||
int (*mmap)(struct device *, struct vm_area_struct *,
|
||||
void *, dma_addr_t, size_t, struct dma_attrs *attrs);
|
||||
|
||||
dma_addr_t (*map_page)(struct device *dev, struct page *page,
|
||||
unsigned long offset, size_t size,
|
||||
enum dma_data_direction dir,
|
||||
|
||||
Reference in new issue
Block a user