aboutsummaryrefslogtreecommitdiffstats
path: root/arch/blackfin/include
diff options
context:
space:
mode:
authorGeert Uytterhoeven <geert@linux-m68k.org>2013-01-27 04:33:21 -0500
committerMarek Szyprowski <m.szyprowski@samsung.com>2013-01-29 02:11:14 -0500
commitafbe21d8b3aedc9d9df0110eaad3d3a816db55ad (patch)
tree719d37461bf90f4ece111eb1ef79c9a280d9dde2 /arch/blackfin/include
parent2e727622ddd14e2cbbe4e756ad4fd1eca915b713 (diff)
blackfin: Provide dma_mmap_coherent() and dma_get_sgtable()
blackfin/allmodconfig: drivers/media/v4l2-core/videobuf2-dma-contig.c: In function ‘vb2_dc_mmap’: drivers/media/v4l2-core/videobuf2-dma-contig.c:204: error: implicit declaration of function ‘dma_mmap_coherent’ drivers/media/v4l2-core/videobuf2-dma-contig.c: In function ‘vb2_dc_get_base_sgt’: drivers/media/v4l2-core/videobuf2-dma-contig.c:387: error: implicit declaration of function ‘dma_get_sgtable’ For architectures using dma_map_ops, dma_mmap_coherent() and dma_get_sgtable() are provided in <asm-generic/dma-mapping-common.h>. Blackfin does not use dma_map_ops, hence it should implement them as inline stubs using dma_common_mmap() and dma_common_get_sgtable(). Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Marek Szyprowski <m.szyprowski@samsung.com> Cc: uclinux-dist-devel@blackfin.uclinux.org Acked-by: Scott Jiang <scott.jiang.linux@gmail.com> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Diffstat (limited to 'arch/blackfin/include')
-rw-r--r--arch/blackfin/include/asm/dma-mapping.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/arch/blackfin/include/asm/dma-mapping.h b/arch/blackfin/include/asm/dma-mapping.h
index bbf461076a0a..054d9ec57d9d 100644
--- a/arch/blackfin/include/asm/dma-mapping.h
+++ b/arch/blackfin/include/asm/dma-mapping.h
@@ -154,4 +154,14 @@ dma_cache_sync(struct device *dev, void *vaddr, size_t size,
154 _dma_sync((dma_addr_t)vaddr, size, dir); 154 _dma_sync((dma_addr_t)vaddr, size, dir);
155} 155}
156 156
157/* drivers/base/dma-mapping.c */
158extern int dma_common_mmap(struct device *dev, struct vm_area_struct *vma,
159 void *cpu_addr, dma_addr_t dma_addr, size_t size);
160extern int dma_common_get_sgtable(struct device *dev, struct sg_table *sgt,
161 void *cpu_addr, dma_addr_t dma_addr,
162 size_t size);
163
164#define dma_mmap_coherent(d, v, c, h, s) dma_common_mmap(d, v, c, h, s)
165#define dma_get_sgtable(d, t, v, h, s) dma_common_get_sgtable(d, t, v, h, s)
166
157#endif /* _BLACKFIN_DMA_MAPPING_H */ 167#endif /* _BLACKFIN_DMA_MAPPING_H */