aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/kernel/dma.c
diff options
context:
space:
mode:
authorAndrzej Pietrasiewicz <andrzej.p@samsung.com>2011-12-06 08:14:46 -0500
committerMarek Szyprowski <m.szyprowski@samsung.com>2012-03-28 10:36:33 -0400
commitbfbf7d615101391c4e24792685b64b38d84d542e (patch)
tree26baa8dac26ae2d159d82348cf2f05098ecf9b35 /arch/powerpc/kernel/dma.c
parente8d51e54ab4020d984dda471ca077c7fed094326 (diff)
PowerPC: adapt for dma_map_ops changes
Adapt core PowerPC architecture code for dma_map_ops changes: replace alloc/free_coherent with generic alloc/free methods. Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@samsung.com> [added missing changes to arch/powerpc/kernel/vio.c] Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Reviewed-by: David Gibson <david@gibson.dropbear.id.au> Reviewed-by: Arnd Bergmann <arnd@arndb.de>
Diffstat (limited to 'arch/powerpc/kernel/dma.c')
-rw-r--r--arch/powerpc/kernel/dma.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/arch/powerpc/kernel/dma.c b/arch/powerpc/kernel/dma.c
index 7d0233c12ee3..b1ec983dcec8 100644
--- a/arch/powerpc/kernel/dma.c
+++ b/arch/powerpc/kernel/dma.c
@@ -26,7 +26,8 @@
26 26
27 27
28void *dma_direct_alloc_coherent(struct device *dev, size_t size, 28void *dma_direct_alloc_coherent(struct device *dev, size_t size,
29 dma_addr_t *dma_handle, gfp_t flag) 29 dma_addr_t *dma_handle, gfp_t flag,
30 struct dma_attrs *attrs)
30{ 31{
31 void *ret; 32 void *ret;
32#ifdef CONFIG_NOT_COHERENT_CACHE 33#ifdef CONFIG_NOT_COHERENT_CACHE
@@ -54,7 +55,8 @@ void *dma_direct_alloc_coherent(struct device *dev, size_t size,
54} 55}
55 56
56void dma_direct_free_coherent(struct device *dev, size_t size, 57void dma_direct_free_coherent(struct device *dev, size_t size,
57 void *vaddr, dma_addr_t dma_handle) 58 void *vaddr, dma_addr_t dma_handle,
59 struct dma_attrs *attrs)
58{ 60{
59#ifdef CONFIG_NOT_COHERENT_CACHE 61#ifdef CONFIG_NOT_COHERENT_CACHE
60 __dma_free_coherent(size, vaddr); 62 __dma_free_coherent(size, vaddr);
@@ -150,8 +152,8 @@ static inline void dma_direct_sync_single(struct device *dev,
150#endif 152#endif
151 153
152struct dma_map_ops dma_direct_ops = { 154struct dma_map_ops dma_direct_ops = {
153 .alloc_coherent = dma_direct_alloc_coherent, 155 .alloc = dma_direct_alloc_coherent,
154 .free_coherent = dma_direct_free_coherent, 156 .free = dma_direct_free_coherent,
155 .map_sg = dma_direct_map_sg, 157 .map_sg = dma_direct_map_sg,
156 .unmap_sg = dma_direct_unmap_sg, 158 .unmap_sg = dma_direct_unmap_sg,
157 .dma_supported = dma_direct_dma_supported, 159 .dma_supported = dma_direct_dma_supported,