diff options
author | Kevin Cernekee <cernekee@gmail.com> | 2009-04-23 20:03:43 -0400 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2009-06-17 06:06:24 -0400 |
commit | d3f634b96a86521f51bbaf04a81e34e7adb0eeb4 (patch) | |
tree | b4c38e61a58deb1a20f2e9cb44a12ccfdc0f8d17 /arch/mips/mm/dma-default.c | |
parent | 7762f206a3f3a19a38ed91a3d87f019d8b4eafc1 (diff) |
MIPS: Add size and direction arguments to plat_unmap_dma_mem()
Signed-off-by: Kevin Cernekee <cernekee@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/mm/dma-default.c')
-rw-r--r-- | arch/mips/mm/dma-default.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/arch/mips/mm/dma-default.c b/arch/mips/mm/dma-default.c index 4fdb7f5216b9..30b108c5782b 100644 --- a/arch/mips/mm/dma-default.c +++ b/arch/mips/mm/dma-default.c | |||
@@ -111,7 +111,7 @@ EXPORT_SYMBOL(dma_alloc_coherent); | |||
111 | void dma_free_noncoherent(struct device *dev, size_t size, void *vaddr, | 111 | void dma_free_noncoherent(struct device *dev, size_t size, void *vaddr, |
112 | dma_addr_t dma_handle) | 112 | dma_addr_t dma_handle) |
113 | { | 113 | { |
114 | plat_unmap_dma_mem(dev, dma_handle); | 114 | plat_unmap_dma_mem(dev, dma_handle, size, DMA_BIDIRECTIONAL); |
115 | free_pages((unsigned long) vaddr, get_order(size)); | 115 | free_pages((unsigned long) vaddr, get_order(size)); |
116 | } | 116 | } |
117 | 117 | ||
@@ -122,7 +122,7 @@ void dma_free_coherent(struct device *dev, size_t size, void *vaddr, | |||
122 | { | 122 | { |
123 | unsigned long addr = (unsigned long) vaddr; | 123 | unsigned long addr = (unsigned long) vaddr; |
124 | 124 | ||
125 | plat_unmap_dma_mem(dev, dma_handle); | 125 | plat_unmap_dma_mem(dev, dma_handle, size, DMA_BIDIRECTIONAL); |
126 | 126 | ||
127 | if (!plat_device_is_coherent(dev)) | 127 | if (!plat_device_is_coherent(dev)) |
128 | addr = CAC_ADDR(addr); | 128 | addr = CAC_ADDR(addr); |
@@ -173,7 +173,7 @@ void dma_unmap_single(struct device *dev, dma_addr_t dma_addr, size_t size, | |||
173 | __dma_sync(dma_addr_to_virt(dma_addr), size, | 173 | __dma_sync(dma_addr_to_virt(dma_addr), size, |
174 | direction); | 174 | direction); |
175 | 175 | ||
176 | plat_unmap_dma_mem(dev, dma_addr); | 176 | plat_unmap_dma_mem(dev, dma_addr, size, direction); |
177 | } | 177 | } |
178 | 178 | ||
179 | EXPORT_SYMBOL(dma_unmap_single); | 179 | EXPORT_SYMBOL(dma_unmap_single); |
@@ -232,7 +232,7 @@ void dma_unmap_sg(struct device *dev, struct scatterlist *sg, int nhwentries, | |||
232 | if (addr) | 232 | if (addr) |
233 | __dma_sync(addr, sg->length, direction); | 233 | __dma_sync(addr, sg->length, direction); |
234 | } | 234 | } |
235 | plat_unmap_dma_mem(dev, sg->dma_address); | 235 | plat_unmap_dma_mem(dev, sg->dma_address, sg->length, direction); |
236 | } | 236 | } |
237 | } | 237 | } |
238 | 238 | ||