aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/platforms
diff options
context:
space:
mode:
authorFUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>2009-08-04 15:08:22 -0400
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2009-08-28 00:24:09 -0400
commit762afb7317b1987fa0851135fe4f2947f68c3c2a (patch)
tree1cf83145c1bdd55b6a166d428af8ee195b09985b /arch/powerpc/platforms
parent2864697cefb6e7596e39aef933b4131f6c9fa9e1 (diff)
powerpc: Remove addr_needs_map in struct dma_mapping_ops
This patch adds max_direct_dma_addr to struct dev_archdata to remove addr_needs_map in struct dma_mapping_ops. It also converts dma_capable() to use max_direct_dma_addr. max_direct_dma_addr is initialized in pci_dma_dev_setup_swiotlb(), called via ppc_md.pci_dma_dev_setup hook. For further information: http://marc.info/?t=124719060200001&r=1&w=2 Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Acked-by: Becky Bruce <beckyb@kernel.crashing.org> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/platforms')
-rw-r--r--arch/powerpc/platforms/85xx/mpc8536_ds.c1
-rw-r--r--arch/powerpc/platforms/85xx/mpc85xx_ds.c1
-rw-r--r--arch/powerpc/platforms/85xx/mpc85xx_mds.c1
-rw-r--r--arch/powerpc/platforms/86xx/mpc86xx_hpcn.c1
4 files changed, 4 insertions, 0 deletions
diff --git a/arch/powerpc/platforms/85xx/mpc8536_ds.c b/arch/powerpc/platforms/85xx/mpc8536_ds.c
index 055ff417bae9..bf052c056106 100644
--- a/arch/powerpc/platforms/85xx/mpc8536_ds.c
+++ b/arch/powerpc/platforms/85xx/mpc8536_ds.c
@@ -97,6 +97,7 @@ static void __init mpc8536_ds_setup_arch(void)
97 if (lmb_end_of_DRAM() > max) { 97 if (lmb_end_of_DRAM() > max) {
98 ppc_swiotlb_enable = 1; 98 ppc_swiotlb_enable = 1;
99 set_pci_dma_ops(&swiotlb_pci_dma_ops); 99 set_pci_dma_ops(&swiotlb_pci_dma_ops);
100 ppc_md.pci_dma_dev_setup = pci_dma_dev_setup_swiotlb;
100 } 101 }
101#endif 102#endif
102 103
diff --git a/arch/powerpc/platforms/85xx/mpc85xx_ds.c b/arch/powerpc/platforms/85xx/mpc85xx_ds.c
index 849c0ac0025f..c6f92ccd963b 100644
--- a/arch/powerpc/platforms/85xx/mpc85xx_ds.c
+++ b/arch/powerpc/platforms/85xx/mpc85xx_ds.c
@@ -193,6 +193,7 @@ static void __init mpc85xx_ds_setup_arch(void)
193 if (lmb_end_of_DRAM() > max) { 193 if (lmb_end_of_DRAM() > max) {
194 ppc_swiotlb_enable = 1; 194 ppc_swiotlb_enable = 1;
195 set_pci_dma_ops(&swiotlb_pci_dma_ops); 195 set_pci_dma_ops(&swiotlb_pci_dma_ops);
196 ppc_md.pci_dma_dev_setup = pci_dma_dev_setup_swiotlb;
196 } 197 }
197#endif 198#endif
198 199
diff --git a/arch/powerpc/platforms/85xx/mpc85xx_mds.c b/arch/powerpc/platforms/85xx/mpc85xx_mds.c
index 20a61d0af33b..25998b661f20 100644
--- a/arch/powerpc/platforms/85xx/mpc85xx_mds.c
+++ b/arch/powerpc/platforms/85xx/mpc85xx_mds.c
@@ -256,6 +256,7 @@ static void __init mpc85xx_mds_setup_arch(void)
256 if (lmb_end_of_DRAM() > max) { 256 if (lmb_end_of_DRAM() > max) {
257 ppc_swiotlb_enable = 1; 257 ppc_swiotlb_enable = 1;
258 set_pci_dma_ops(&swiotlb_pci_dma_ops); 258 set_pci_dma_ops(&swiotlb_pci_dma_ops);
259 ppc_md.pci_dma_dev_setup = pci_dma_dev_setup_swiotlb;
259 } 260 }
260#endif 261#endif
261} 262}
diff --git a/arch/powerpc/platforms/86xx/mpc86xx_hpcn.c b/arch/powerpc/platforms/86xx/mpc86xx_hpcn.c
index 66327024a6a6..803230156875 100644
--- a/arch/powerpc/platforms/86xx/mpc86xx_hpcn.c
+++ b/arch/powerpc/platforms/86xx/mpc86xx_hpcn.c
@@ -106,6 +106,7 @@ mpc86xx_hpcn_setup_arch(void)
106 if (lmb_end_of_DRAM() > max) { 106 if (lmb_end_of_DRAM() > max) {
107 ppc_swiotlb_enable = 1; 107 ppc_swiotlb_enable = 1;
108 set_pci_dma_ops(&swiotlb_pci_dma_ops); 108 set_pci_dma_ops(&swiotlb_pci_dma_ops);
109 ppc_md.pci_dma_dev_setup = pci_dma_dev_setup_swiotlb;
109 } 110 }
110#endif 111#endif
111} 112}