diff options
Diffstat (limited to 'arch/mips/include/asm/dma-mapping.h')
-rw-r--r-- | arch/mips/include/asm/dma-mapping.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/arch/mips/include/asm/dma-mapping.h b/arch/mips/include/asm/dma-mapping.h index 555efa5773..639511226d 100644 --- a/arch/mips/include/asm/dma-mapping.h +++ b/arch/mips/include/asm/dma-mapping.h @@ -12,12 +12,14 @@ static inline void *dma_alloc_coherent(size_t size, dma_addr_t *dma_handle) ret = xmemalign(PAGE_SIZE, size); - *dma_handle = CPHYSADDR(ret); + if (dma_handle) + *dma_handle = CPHYSADDR(ret); return (void *)CKSEG1ADDR(ret); } -static inline void dma_free_coherent(void *vaddr) +static inline void dma_free_coherent(void *vaddr, dma_addr_t dma_handle, + size_t size) { free(vaddr); } |