diff options
Diffstat (limited to 'arch/sparc/mm/io-unit.c')
-rw-r--r-- | arch/sparc/mm/io-unit.c | 23 |
1 files changed, 13 insertions, 10 deletions
diff --git a/arch/sparc/mm/io-unit.c b/arch/sparc/mm/io-unit.c index d175c0ae5e4..eb99862e965 100644 --- a/arch/sparc/mm/io-unit.c +++ b/arch/sparc/mm/io-unit.c | |||
@@ -197,7 +197,7 @@ static void iounit_release_scsi_sgl(struct device *dev, struct scatterlist *sg, | |||
197 | } | 197 | } |
198 | 198 | ||
199 | #ifdef CONFIG_SBUS | 199 | #ifdef CONFIG_SBUS |
200 | static int iounit_map_dma_area(struct device *dev, dma_addr_t *pba, unsigned long va, __u32 addr, int len) | 200 | static int iounit_map_dma_area(struct device *dev, dma_addr_t *pba, unsigned long va, unsigned long addr, int len) |
201 | { | 201 | { |
202 | struct iounit_struct *iounit = dev->archdata.iommu; | 202 | struct iounit_struct *iounit = dev->archdata.iommu; |
203 | unsigned long page, end; | 203 | unsigned long page, end; |
@@ -242,15 +242,18 @@ static void iounit_unmap_dma_area(struct device *dev, unsigned long addr, int le | |||
242 | } | 242 | } |
243 | #endif | 243 | #endif |
244 | 244 | ||
245 | void __init ld_mmu_iounit(void) | 245 | static const struct sparc32_dma_ops iounit_dma_ops = { |
246 | { | 246 | .get_scsi_one = iounit_get_scsi_one, |
247 | BTFIXUPSET_CALL(mmu_get_scsi_one, iounit_get_scsi_one, BTFIXUPCALL_NORM); | 247 | .get_scsi_sgl = iounit_get_scsi_sgl, |
248 | BTFIXUPSET_CALL(mmu_get_scsi_sgl, iounit_get_scsi_sgl, BTFIXUPCALL_NORM); | 248 | .release_scsi_one = iounit_release_scsi_one, |
249 | BTFIXUPSET_CALL(mmu_release_scsi_one, iounit_release_scsi_one, BTFIXUPCALL_NORM); | 249 | .release_scsi_sgl = iounit_release_scsi_sgl, |
250 | BTFIXUPSET_CALL(mmu_release_scsi_sgl, iounit_release_scsi_sgl, BTFIXUPCALL_NORM); | ||
251 | |||
252 | #ifdef CONFIG_SBUS | 250 | #ifdef CONFIG_SBUS |
253 | BTFIXUPSET_CALL(mmu_map_dma_area, iounit_map_dma_area, BTFIXUPCALL_NORM); | 251 | .map_dma_area = iounit_map_dma_area, |
254 | BTFIXUPSET_CALL(mmu_unmap_dma_area, iounit_unmap_dma_area, BTFIXUPCALL_NORM); | 252 | .unmap_dma_area = iounit_unmap_dma_area, |
255 | #endif | 253 | #endif |
254 | }; | ||
255 | |||
256 | void __init ld_mmu_iounit(void) | ||
257 | { | ||
258 | sparc32_dma_ops = &iounit_dma_ops; | ||
256 | } | 259 | } |