aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sparc/kernel/dma.c
diff options
context:
space:
mode:
authorFUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>2009-08-09 22:53:15 -0400
committerIngo Molnar <mingo@elte.hu>2009-08-10 03:35:00 -0400
commitc2c07dbd8742a26ab3f1ee8b82237a060a0d9f61 (patch)
tree63bfb1f03d625e6baefd19f0d52d99f98c539742 /arch/sparc/kernel/dma.c
parent595cc8560783ea31ed1208dc1f97282a2a5606b7 (diff)
sparc: Replace sbus_map_single and sbus_unmap_single with sbus_map_page and sbus_unmap_page
This is a preparation for using asm-generic/pci-dma-compat.h; SPARC32 has two dma_map_ops structures for pci and sbus (removing arch/sparc/kernel/dma.c, PCI and SBUS DMA accessor). Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Tested-by: Robert Reif <reif@earthlink.net> Acked-by: David S. Miller <davem@davemloft.net> Cc: tony.luck@intel.com Cc: fenghua.yu@intel.com LKML-Reference: <1249872797-1314-7-git-send-email-fujita.tomonori@lab.ntt.co.jp> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/sparc/kernel/dma.c')
-rw-r--r--arch/sparc/kernel/dma.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/arch/sparc/kernel/dma.c b/arch/sparc/kernel/dma.c
index 15820a918171..a5d50dac735c 100644
--- a/arch/sparc/kernel/dma.c
+++ b/arch/sparc/kernel/dma.c
@@ -68,8 +68,7 @@ static dma_addr_t dma32_map_page(struct device *dev, struct page *page,
68 return pci_map_page(to_pci_dev(dev), page, offset, 68 return pci_map_page(to_pci_dev(dev), page, offset,
69 size, (int)direction); 69 size, (int)direction);
70#endif 70#endif
71 return sbus_map_single(dev, page_address(page) + offset, 71 return sbus_map_page(dev, page, offset, size, (int)direction);
72 size, (int)direction);
73} 72}
74 73
75static void dma32_unmap_page(struct device *dev, dma_addr_t dma_address, 74static void dma32_unmap_page(struct device *dev, dma_addr_t dma_address,
@@ -83,7 +82,7 @@ static void dma32_unmap_page(struct device *dev, dma_addr_t dma_address,
83 return; 82 return;
84 } 83 }
85#endif 84#endif
86 sbus_unmap_single(dev, dma_address, size, (int)direction); 85 sbus_unmap_page(dev, dma_address, size, (int)direction);
87} 86}
88 87
89static int dma32_map_sg(struct device *dev, struct scatterlist *sg, 88static int dma32_map_sg(struct device *dev, struct scatterlist *sg,