diff options
author | Hiroshi Doyu <hdoyu@nvidia.com> | 2013-09-16 08:56:57 +0300 |
---|---|---|
committer | Dan Willemsen <dwillemsen@nvidia.com> | 2013-09-26 19:45:47 -0700 |
commit | 4bb1f567f582d27a95143b948a95f8c85dcebbed (patch) | |
tree | 36fbfd74c60e85d727b4853aaf27d03f666609f4 /arch/arm/include | |
parent | faef5863b219a765c37f6e90bc587e8c61d566d2 (diff) |
ARM: dma-mapping: IOVA API chagne
Needed along with the common IOVA API chagne to pass DMA attribute.
Bug 1303110
Bug 1173494
Change-Id: Ia12984bbaf2486b0c1031feae983967e011270f2
Signed-off-by: Hiroshi Doyu <hdoyu@nvidia.com>
Reviewed-on: http://git-master/r/275019
Diffstat (limited to 'arch/arm/include')
-rw-r--r-- | arch/arm/include/asm/dma-mapping.h | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/arch/arm/include/asm/dma-mapping.h b/arch/arm/include/asm/dma-mapping.h index 048a973ec094..79de3501b251 100644 --- a/arch/arm/include/asm/dma-mapping.h +++ b/arch/arm/include/asm/dma-mapping.h @@ -186,30 +186,31 @@ static inline void dma_free_attrs(struct device *dev, size_t size, ops->free(dev, size, cpu_addr, dma_handle, attrs); } -static inline dma_addr_t dma_iova_alloc(struct device *dev, size_t size) +static inline dma_addr_t dma_iova_alloc(struct device *dev, size_t size, + struct dma_attrs *attrs) { struct dma_map_ops *ops = get_dma_ops(dev); BUG_ON(!ops); - return ops->iova_alloc(dev, size); + return ops->iova_alloc(dev, size, attrs); } static inline void dma_iova_free(struct device *dev, dma_addr_t addr, - size_t size) + size_t size, struct dma_attrs *attrs) { struct dma_map_ops *ops = get_dma_ops(dev); BUG_ON(!ops); - ops->iova_free(dev, addr, size); + ops->iova_free(dev, addr, size, attrs); } static inline dma_addr_t dma_iova_alloc_at(struct device *dev, dma_addr_t *addr, - size_t size) + size_t size, struct dma_attrs *attrs) { struct dma_map_ops *ops = get_dma_ops(dev); BUG_ON(!ops); - return ops->iova_alloc_at(dev, addr, size); + return ops->iova_alloc_at(dev, addr, size, attrs); } static inline size_t dma_iova_get_free_total(struct device *dev) @@ -238,7 +239,7 @@ dma_map_linear_attrs(struct device *dev, phys_addr_t pa, size_t size, struct dma_map_ops *ops = get_dma_ops(dev); dma_addr_t addr; - da = dma_iova_alloc_at(dev, &req, size); + da = dma_iova_alloc_at(dev, &req, size, attrs); if (da == DMA_ERROR_CODE) { DEFINE_DMA_ATTRS(_attrs); switch (req) { |