diff options
| author | Bart Van Assche <[email protected]> | 2017-01-20 13:04:03 -0800 |
|---|---|---|
| committer | Doug Ledford <[email protected]> | 2017-01-24 12:23:35 -0500 |
| commit | ca6e8e1031419549f67291ca31b43126f07cecdb (patch) | |
| tree | 198ea3d5b75d087a1be9e9d029dd1e03055be09c /include/linux | |
| parent | 5657933dbb6e25feaf5d8df8c88f96cdade693a3 (diff) | |
treewide: Consolidate set_dma_ops() implementations
Now that all set_dma_ops() implementations are identical (ignoring
BUG_ON() statements), remove the architecture specific definitions
and add a definition in <linux/dma-mapping.h>.
Signed-off-by: Bart Van Assche <[email protected]>
Cc: Benjamin Herrenschmidt <[email protected]>
Cc: Chris Metcalf <[email protected]>
Cc: David Woodhouse <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Cc: Paul Mackerras <[email protected]>
Cc: Russell King <[email protected]>
Signed-off-by: Doug Ledford <[email protected]>
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/dma-mapping.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/dma-mapping.h b/include/linux/dma-mapping.h index f1da68b82c63..e97f23e8b2d9 100644 --- a/include/linux/dma-mapping.h +++ b/include/linux/dma-mapping.h @@ -164,6 +164,11 @@ int dma_mmap_from_coherent(struct device *dev, struct vm_area_struct *vma, #ifdef CONFIG_HAS_DMA #include <asm/dma-mapping.h> +static inline void set_dma_ops(struct device *dev, + const struct dma_map_ops *dma_ops) +{ + dev->dma_ops = dma_ops; +} #else /* * Define the dma api to allow compilation but not linking of |