aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-powerpc/iommu.h
diff options
context:
space:
mode:
authorMark Nelson <markn@au1.ibm.com>2008-07-04 15:05:42 -0400
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2008-07-09 02:30:43 -0400
commit3affedc4e1ce837033b6c5e9289d2ce2f5a62d31 (patch)
tree83296af2c727e5b5f64b88b629dcf37f8e60e3f0 /include/asm-powerpc/iommu.h
parentc8692362db3db3a6f644e05a477161d967430aac (diff)
powerpc/dma: implement new dma_*map*_attrs() interfaces
Update powerpc to use the new dma_*map*_attrs() interfaces. In doing so update struct dma_mapping_ops to accept a struct dma_attrs and propagate these changes through to all users of the code (generic IOMMU and the 64bit DMA code, and the iseries and ps3 platform code). The old dma_*map_*() interfaces are reimplemented as calls to the corresponding new interfaces. Signed-off-by: Mark Nelson <markn@au1.ibm.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Geoff Levand <geoffrey.levand@am.sony.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'include/asm-powerpc/iommu.h')
-rw-r--r--include/asm-powerpc/iommu.h12
1 files changed, 8 insertions, 4 deletions
diff --git a/include/asm-powerpc/iommu.h b/include/asm-powerpc/iommu.h
index 65f6682bee87..51ecfef8d843 100644
--- a/include/asm-powerpc/iommu.h
+++ b/include/asm-powerpc/iommu.h
@@ -81,9 +81,11 @@ extern struct iommu_table *iommu_init_table(struct iommu_table * tbl,
81 81
82extern int iommu_map_sg(struct device *dev, struct iommu_table *tbl, 82extern int iommu_map_sg(struct device *dev, struct iommu_table *tbl,
83 struct scatterlist *sglist, int nelems, 83 struct scatterlist *sglist, int nelems,
84 unsigned long mask, enum dma_data_direction direction); 84 unsigned long mask, enum dma_data_direction direction,
85 struct dma_attrs *attrs);
85extern void iommu_unmap_sg(struct iommu_table *tbl, struct scatterlist *sglist, 86extern void iommu_unmap_sg(struct iommu_table *tbl, struct scatterlist *sglist,
86 int nelems, enum dma_data_direction direction); 87 int nelems, enum dma_data_direction direction,
88 struct dma_attrs *attrs);
87 89
88extern void *iommu_alloc_coherent(struct device *dev, struct iommu_table *tbl, 90extern void *iommu_alloc_coherent(struct device *dev, struct iommu_table *tbl,
89 size_t size, dma_addr_t *dma_handle, 91 size_t size, dma_addr_t *dma_handle,
@@ -92,9 +94,11 @@ extern void iommu_free_coherent(struct iommu_table *tbl, size_t size,
92 void *vaddr, dma_addr_t dma_handle); 94 void *vaddr, dma_addr_t dma_handle);
93extern dma_addr_t iommu_map_single(struct device *dev, struct iommu_table *tbl, 95extern dma_addr_t iommu_map_single(struct device *dev, struct iommu_table *tbl,
94 void *vaddr, size_t size, unsigned long mask, 96 void *vaddr, size_t size, unsigned long mask,
95 enum dma_data_direction direction); 97 enum dma_data_direction direction,
98 struct dma_attrs *attrs);
96extern void iommu_unmap_single(struct iommu_table *tbl, dma_addr_t dma_handle, 99extern void iommu_unmap_single(struct iommu_table *tbl, dma_addr_t dma_handle,
97 size_t size, enum dma_data_direction direction); 100 size_t size, enum dma_data_direction direction,
101 struct dma_attrs *attrs);
98 102
99extern void iommu_init_early_pSeries(void); 103extern void iommu_init_early_pSeries(void);
100extern void iommu_init_early_iSeries(void); 104extern void iommu_init_early_iSeries(void);