diff options
author | Hiroshi Doyu <hdoyu@nvidia.com> | 2013-01-24 15:16:56 +0200 |
---|---|---|
committer | Marek Szyprowski <m.szyprowski@samsung.com> | 2013-02-25 15:30:41 +0100 |
commit | fab112a394b9cf5e3bf888af6ff5076ba9fa0f06 (patch) | |
tree | 0796a9f812a400c786a3a8c9cee0f19e361171c5 | |
parent | d09e1333ec6c8c6fe2875dc2763ebbac84efe8d7 (diff) |
ARM: dma-mapping: Add macro to_dma_iommu_mapping()
This can be built without CONFIG_ARM_DMA_USE_IOMMU.
Signed-off-by: Hiroshi Doyu <hdoyu@nvidia.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
-rw-r--r-- | arch/arm/include/asm/device.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/arch/arm/include/asm/device.h b/arch/arm/include/asm/device.h index b69c0d3285f..dc662fca923 100644 --- a/arch/arm/include/asm/device.h +++ b/arch/arm/include/asm/device.h @@ -27,4 +27,10 @@ struct pdev_archdata { #endif }; +#ifdef CONFIG_ARM_DMA_USE_IOMMU +#define to_dma_iommu_mapping(dev) ((dev)->archdata.mapping) +#else +#define to_dma_iommu_mapping(dev) NULL +#endif + #endif |