summaryrefslogtreecommitdiff
path: root/include/linux/dma-mapping.h
diff options
context:
space:
mode:
authorFUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>2008-09-18 21:02:05 +0400
committerIngo Molnar <mingo@elte.hu>2008-09-19 12:20:41 +0400
commit07a2c01a0c2a0cb4581a67d50d4f17cb4d2457c4 (patch)
tree2c01e2ee314cf62e5a96cf7c6bde49a377a446df /include/linux/dma-mapping.h
parentf6a32a36ab96016675cd414802904feb288d7899 (diff)
downloadlinux-07a2c01a0c2a0cb4581a67d50d4f17cb4d2457c4.tar.xz
convert swiotlb to use dma_get_mask
swiotlb can use dma_get_mask() instead of the homegrown function. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Cc: tony.luck@intel.com Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include/linux/dma-mapping.h')
-rw-r--r--include/linux/dma-mapping.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/dma-mapping.h b/include/linux/dma-mapping.h
index 0dba7433af18..ba9114ec5d3a 100644
--- a/include/linux/dma-mapping.h
+++ b/include/linux/dma-mapping.h
@@ -65,7 +65,7 @@ static inline int is_buffer_dma_capable(u64 mask, dma_addr_t addr, size_t size)
static inline u64 dma_get_mask(struct device *dev)
{
- if (dev->dma_mask && *dev->dma_mask)
+ if (dev && dev->dma_mask && *dev->dma_mask)
return *dev->dma_mask;
return DMA_32BIT_MASK;
}