aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/sh/mm/consistent.c10
1 files changed, 0 insertions, 10 deletions
diff --git a/arch/sh/mm/consistent.c b/arch/sh/mm/consistent.c
index 7619a0fae086..9f8ea3ada4db 100644
--- a/arch/sh/mm/consistent.c
+++ b/arch/sh/mm/consistent.c
@@ -16,14 +16,6 @@
16#include <asm/addrspace.h> 16#include <asm/addrspace.h>
17#include <asm/io.h> 17#include <asm/io.h>
18 18
19struct dma_coherent_mem {
20 void *virt_base;
21 u32 device_base;
22 int size;
23 int flags;
24 unsigned long *bitmap;
25};
26
27void *dma_alloc_coherent(struct device *dev, size_t size, 19void *dma_alloc_coherent(struct device *dev, size_t size,
28 dma_addr_t *dma_handle, gfp_t gfp) 20 dma_addr_t *dma_handle, gfp_t gfp)
29{ 21{
@@ -58,12 +50,10 @@ EXPORT_SYMBOL(dma_alloc_coherent);
58void dma_free_coherent(struct device *dev, size_t size, 50void dma_free_coherent(struct device *dev, size_t size,
59 void *vaddr, dma_addr_t dma_handle) 51 void *vaddr, dma_addr_t dma_handle)
60{ 52{
61 struct dma_coherent_mem *mem = dev ? dev->dma_mem : NULL;
62 int order = get_order(size); 53 int order = get_order(size);
63 54
64 if (!dma_release_from_coherent(dev, order, vaddr)) { 55 if (!dma_release_from_coherent(dev, order, vaddr)) {
65 WARN_ON(irqs_disabled()); /* for portability */ 56 WARN_ON(irqs_disabled()); /* for portability */
66 BUG_ON(mem && mem->flags & DMA_MEMORY_EXCLUSIVE);
67 free_pages((unsigned long)phys_to_virt(dma_handle), order); 57 free_pages((unsigned long)phys_to_virt(dma_handle), order);
68 iounmap(vaddr); 58 iounmap(vaddr);
69 } 59 }