sparc: dma-mapping: support debug_dma_mapping_error
authorShuah Khan <shuahkhan@gmail.com>
Fri, 26 Oct 2012 00:31:42 +0000 (18:31 -0600)
committerJoerg Roedel <joro@8bytes.org>
Sat, 17 Nov 2012 12:20:38 +0000 (13:20 +0100)
Add support for debug_dma_mapping_error() call to avoid warning from
debug_dma_unmap() interface when it checks for mapping error checked
status. Without this patch, device driver failed to check map error
warning is generated.

Signed-off-by: Shuah Khan <shuah.khan@hp.com>
Acked-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Joerg Roedel <joro@8bytes.org>
arch/sparc/include/asm/dma-mapping.h

index 8493fd3c7ba5a5ea39364948c26ecdd4feef41b8..05fe53f5346e2750d1d04b945741c06f6373f7ef 100644 (file)
@@ -59,6 +59,7 @@ static inline void dma_free_attrs(struct device *dev, size_t size,
 
 static inline int dma_mapping_error(struct device *dev, dma_addr_t dma_addr)
 {
+       debug_dma_mapping_error(dev, dma_addr);
        return (dma_addr == DMA_ERROR_CODE);
 }