aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sparc/kernel/iommu.c
diff options
context:
space:
mode:
authorAndrzej Pietrasiewicz <andrzej.p@samsung.com>2012-03-27 08:56:55 -0400
committerMarek Szyprowski <m.szyprowski@samsung.com>2012-03-28 10:36:34 -0400
commitc416258a6e1e68a33fd328e872007d19941138c5 (patch)
tree037c2d890c29dad4caff129cf351dbc24bd27082 /arch/sparc/kernel/iommu.c
parentbfbf7d615101391c4e24792685b64b38d84d542e (diff)
SPARC: adapt for dma_map_ops changes
Adapt core SPARC architecture code for dma_map_ops changes: replace alloc/free_coherent with generic alloc/free methods. Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@samsung.com> Acked-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Acked-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc/kernel/iommu.c')
-rw-r--r--arch/sparc/kernel/iommu.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/arch/sparc/kernel/iommu.c b/arch/sparc/kernel/iommu.c
index 4643d68713fa..070ed141aac7 100644
--- a/arch/sparc/kernel/iommu.c
+++ b/arch/sparc/kernel/iommu.c
@@ -280,7 +280,8 @@ static inline void iommu_free_ctx(struct iommu *iommu, int ctx)
280} 280}
281 281
282static void *dma_4u_alloc_coherent(struct device *dev, size_t size, 282static void *dma_4u_alloc_coherent(struct device *dev, size_t size,
283 dma_addr_t *dma_addrp, gfp_t gfp) 283 dma_addr_t *dma_addrp, gfp_t gfp,
284 struct dma_attrs *attrs)
284{ 285{
285 unsigned long flags, order, first_page; 286 unsigned long flags, order, first_page;
286 struct iommu *iommu; 287 struct iommu *iommu;
@@ -330,7 +331,8 @@ static void *dma_4u_alloc_coherent(struct device *dev, size_t size,
330} 331}
331 332
332static void dma_4u_free_coherent(struct device *dev, size_t size, 333static void dma_4u_free_coherent(struct device *dev, size_t size,
333 void *cpu, dma_addr_t dvma) 334 void *cpu, dma_addr_t dvma,
335 struct dma_attrs *attrs)
334{ 336{
335 struct iommu *iommu; 337 struct iommu *iommu;
336 unsigned long flags, order, npages; 338 unsigned long flags, order, npages;
@@ -825,8 +827,8 @@ static void dma_4u_sync_sg_for_cpu(struct device *dev,
825} 827}
826 828
827static struct dma_map_ops sun4u_dma_ops = { 829static struct dma_map_ops sun4u_dma_ops = {
828 .alloc_coherent = dma_4u_alloc_coherent, 830 .alloc = dma_4u_alloc_coherent,
829 .free_coherent = dma_4u_free_coherent, 831 .free = dma_4u_free_coherent,
830 .map_page = dma_4u_map_page, 832 .map_page = dma_4u_map_page,
831 .unmap_page = dma_4u_unmap_page, 833 .unmap_page = dma_4u_unmap_page,
832 .map_sg = dma_4u_map_sg, 834 .map_sg = dma_4u_map_sg,