]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
ENGR00220181-1 DMA: remove noncacheable memory allocation limit.
authorChen Liangjun <b36089@freescale.com>
Mon, 13 Aug 2012 07:52:19 +0000 (15:52 +0800)
committerLothar Waßmann <LW@KARO-electronics.de>
Fri, 24 May 2013 06:35:12 +0000 (08:35 +0200)
DMA interface dma_alloc_noncacheable() is only used by USB. HDMI audio
driver also need the interface to allocate C=0 B=0 type memory.

In this patch, remove MACRO limitation and make dma_alloc_noncacheable()
common code for other modules.

Signed-off-by: Chen Liangjun <b36089@freescale.com>
arch/arm/include/asm/dma-mapping.h
arch/arm/mm/dma-mapping.c

index b52c063203dc31c89c23159eaa107d5617fc6e3a..635c940cd060de9efe3dfab945a406a18f4d0ff6 100644 (file)
@@ -198,8 +198,6 @@ extern void *dma_alloc_coherent(struct device *, size_t, dma_addr_t *, gfp_t);
  */
 extern void *dma_alloc_writethrough(struct device *, size_t, dma_addr_t *, gfp_t);
 
-
-#ifdef CONFIG_FSL_UTP
 /**
  * dma_alloc_noncacheable - allocate consistent memory for DMA
  * @dev: valid struct device pointer, or NULL for ISA and EISA-like devices
@@ -212,7 +210,6 @@ extern void *dma_alloc_writethrough(struct device *, size_t, dma_addr_t *, gfp_t
  * device-viewed address.
  */
 extern void *dma_alloc_noncacheable(struct device *, size_t, dma_addr_t *, gfp_t);
-#endif
 
 /**
  * dma_free_coherent - free memory allocated by dma_alloc_coherent
index e134cfff3ba1275d5714cd4d2f94a81b052e1b5d..0f0baddf4eb91a87d6617af8bf23a317409fef7b 100644 (file)
@@ -369,8 +369,6 @@ dma_alloc_writethrough(struct device *dev, size_t size, dma_addr_t *handle, gfp_
 }
 EXPORT_SYMBOL(dma_alloc_writethrough);
 
-
-#ifdef CONFIG_FSL_UTP
 /*
  *  Allocate noncacheable memory space and return both the kernel remapped
  * virtual and bus address for that space.
@@ -383,7 +381,6 @@ dma_alloc_noncacheable(struct device *dev, size_t size, dma_addr_t *handle, gfp_
                          pgprot_noncached(pgprot_kernel));
 }
 EXPORT_SYMBOL(dma_alloc_noncacheable);
-#endif
 
 static int dma_mmap(struct device *dev, struct vm_area_struct *vma,
                    void *cpu_addr, dma_addr_t dma_addr, size_t size)