aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorJan Beulich <jbeulich@novell.com>2007-07-09 14:55:51 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2007-07-11 19:02:11 -0400
commitcaa5171622c8fef70fa20d2d74f4326866039df9 (patch)
treeeee98d71a3d57db4fcadd6bcca2612b64c367083 /include
parentb7b095c154c50ee753832bbf78e8690c492fc8f6 (diff)
PCI: remove pci_dac_dma_... APIs
Based on replies to a respective query, remove the pci_dac_dma_...() APIs (except for pci_dac_dma_supported() on Alpha, where this function is used in non-DAC PCI DMA code). Signed-off-by: Jan Beulich <jbeulich@novell.com> Cc: Andi Kleen <ak@suse.de> Cc: Jesse Barnes <jesse.barnes@intel.com> Cc: Christoph Hellwig <hch@infradead.org> Acked-by: David Miller <davem@davemloft.net> Cc: Jeff Garzik <jeff@garzik.org> Cc: <linux-arch@vger.kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'include')
-rw-r--r--include/asm-alpha/pci.h24
-rw-r--r--include/asm-arm/pci.h5
-rw-r--r--include/asm-cris/pci.h32
-rw-r--r--include/asm-frv/pci.h3
-rw-r--r--include/asm-i386/pci.h33
-rw-r--r--include/asm-ia64/pci.h8
-rw-r--r--include/asm-m68knommu/pci.h6
-rw-r--r--include/asm-mips/pci.h14
-rw-r--r--include/asm-parisc/pci.h3
-rw-r--r--include/asm-powerpc/dma-mapping.h1
-rw-r--r--include/asm-powerpc/pci.h18
-rw-r--r--include/asm-ppc/pci.h6
-rw-r--r--include/asm-sh/pci.h5
-rw-r--r--include/asm-sh64/pci.h5
-rw-r--r--include/asm-sparc/pci.h2
-rw-r--r--include/asm-sparc64/pci.h43
-rw-r--r--include/asm-v850/rte_cb.h1
-rw-r--r--include/asm-x86_64/pci.h40
-rw-r--r--include/asm-xtensa/pci.h3
19 files changed, 0 insertions, 252 deletions
diff --git a/include/asm-alpha/pci.h b/include/asm-alpha/pci.h
index 635d6f2b0b03..30ee7669b19f 100644
--- a/include/asm-alpha/pci.h
+++ b/include/asm-alpha/pci.h
@@ -199,30 +199,6 @@ pci_dma_sync_sg_for_device(struct pci_dev *dev, struct scatterlist *sg,
199 199
200extern int pci_dma_supported(struct pci_dev *hwdev, u64 mask); 200extern int pci_dma_supported(struct pci_dev *hwdev, u64 mask);
201 201
202/* True if the machine supports DAC addressing, and DEV can
203 make use of it given MASK. */
204extern int pci_dac_dma_supported(struct pci_dev *hwdev, u64 mask);
205
206/* Convert to/from DAC dma address and struct page. */
207extern dma64_addr_t pci_dac_page_to_dma(struct pci_dev *, struct page *,
208 unsigned long, int);
209extern struct page *pci_dac_dma_to_page(struct pci_dev *, dma64_addr_t);
210extern unsigned long pci_dac_dma_to_offset(struct pci_dev *, dma64_addr_t);
211
212static inline void
213pci_dac_dma_sync_single_for_cpu(struct pci_dev *pdev, dma64_addr_t dma_addr,
214 size_t len, int direction)
215{
216 /* Nothing to do. */
217}
218
219static inline void
220pci_dac_dma_sync_single_for_device(struct pci_dev *pdev, dma64_addr_t dma_addr,
221 size_t len, int direction)
222{
223 /* Nothing to do. */
224}
225
226#ifdef CONFIG_PCI 202#ifdef CONFIG_PCI
227static inline void pci_dma_burst_advice(struct pci_dev *pdev, 203static inline void pci_dma_burst_advice(struct pci_dev *pdev,
228 enum pci_dma_burst_strategy *strat, 204 enum pci_dma_burst_strategy *strat,
diff --git a/include/asm-arm/pci.h b/include/asm-arm/pci.h
index 9299a3c1ac37..ed3f898191f4 100644
--- a/include/asm-arm/pci.h
+++ b/include/asm-arm/pci.h
@@ -26,11 +26,6 @@ static inline void pcibios_penalize_isa_irq(int irq, int active)
26#define PCI_DMA_BUS_IS_PHYS (0) 26#define PCI_DMA_BUS_IS_PHYS (0)
27 27
28/* 28/*
29 * We don't support DAC DMA cycles.
30 */
31#define pci_dac_dma_supported(pci_dev, mask) (0)
32
33/*
34 * Whether pci_unmap_{single,page} is a nop depends upon the 29 * Whether pci_unmap_{single,page} is a nop depends upon the
35 * configuration. 30 * configuration.
36 */ 31 */
diff --git a/include/asm-cris/pci.h b/include/asm-cris/pci.h
index 5f1986ef7db1..730ce40fdd0f 100644
--- a/include/asm-cris/pci.h
+++ b/include/asm-cris/pci.h
@@ -52,38 +52,6 @@ struct pci_dev;
52#define pci_unmap_len(PTR, LEN_NAME) (0) 52#define pci_unmap_len(PTR, LEN_NAME) (0)
53#define pci_unmap_len_set(PTR, LEN_NAME, VAL) do { } while (0) 53#define pci_unmap_len_set(PTR, LEN_NAME, VAL) do { } while (0)
54 54
55/* This is always fine. */
56#define pci_dac_dma_supported(pci_dev, mask) (1)
57
58static inline dma64_addr_t
59pci_dac_page_to_dma(struct pci_dev *pdev, struct page *page, unsigned long offset, int direction)
60{
61 return ((dma64_addr_t) page_to_phys(page) +
62 (dma64_addr_t) offset);
63}
64
65static inline struct page *
66pci_dac_dma_to_page(struct pci_dev *pdev, dma64_addr_t dma_addr)
67{
68 return pfn_to_page(dma_addr >> PAGE_SHIFT);
69}
70
71static inline unsigned long
72pci_dac_dma_to_offset(struct pci_dev *pdev, dma64_addr_t dma_addr)
73{
74 return (dma_addr & ~PAGE_MASK);
75}
76
77static inline void
78pci_dac_dma_sync_single_for_cpu(struct pci_dev *pdev, dma64_addr_t dma_addr, size_t len, int direction)
79{
80}
81
82static inline void
83pci_dac_dma_sync_single_for_device(struct pci_dev *pdev, dma64_addr_t dma_addr, size_t len, int direction)
84{
85}
86
87#define HAVE_PCI_MMAP 55#define HAVE_PCI_MMAP
88extern int pci_mmap_page_range(struct pci_dev *dev, struct vm_area_struct *vma, 56extern int pci_mmap_page_range(struct pci_dev *dev, struct vm_area_struct *vma,
89 enum pci_mmap_state mmap_state, int write_combine); 57 enum pci_mmap_state mmap_state, int write_combine);
diff --git a/include/asm-frv/pci.h b/include/asm-frv/pci.h
index 3aee08c5a44f..585d9b49949a 100644
--- a/include/asm-frv/pci.h
+++ b/include/asm-frv/pci.h
@@ -40,9 +40,6 @@ extern void *pci_alloc_consistent(struct pci_dev *hwdev, size_t size,
40extern void pci_free_consistent(struct pci_dev *hwdev, size_t size, 40extern void pci_free_consistent(struct pci_dev *hwdev, size_t size,
41 void *vaddr, dma_addr_t dma_handle); 41 void *vaddr, dma_addr_t dma_handle);
42 42
43/* This is always fine. */
44#define pci_dac_dma_supported(pci_dev, mask) (1)
45
46/* Return the index of the PCI controller for device PDEV. */ 43/* Return the index of the PCI controller for device PDEV. */
47#define pci_controller_num(PDEV) (0) 44#define pci_controller_num(PDEV) (0)
48 45
diff --git a/include/asm-i386/pci.h b/include/asm-i386/pci.h
index b974bd8ce9c6..392d3fe5d45e 100644
--- a/include/asm-i386/pci.h
+++ b/include/asm-i386/pci.h
@@ -56,39 +56,6 @@ struct pci_dev;
56#define pci_unmap_len(PTR, LEN_NAME) (0) 56#define pci_unmap_len(PTR, LEN_NAME) (0)
57#define pci_unmap_len_set(PTR, LEN_NAME, VAL) do { } while (0) 57#define pci_unmap_len_set(PTR, LEN_NAME, VAL) do { } while (0)
58 58
59/* This is always fine. */
60#define pci_dac_dma_supported(pci_dev, mask) (1)
61
62static inline dma64_addr_t
63pci_dac_page_to_dma(struct pci_dev *pdev, struct page *page, unsigned long offset, int direction)
64{
65 return ((dma64_addr_t) page_to_phys(page) +
66 (dma64_addr_t) offset);
67}
68
69static inline struct page *
70pci_dac_dma_to_page(struct pci_dev *pdev, dma64_addr_t dma_addr)
71{
72 return pfn_to_page(dma_addr >> PAGE_SHIFT);
73}
74
75static inline unsigned long
76pci_dac_dma_to_offset(struct pci_dev *pdev, dma64_addr_t dma_addr)
77{
78 return (dma_addr & ~PAGE_MASK);
79}
80
81static inline void
82pci_dac_dma_sync_single_for_cpu(struct pci_dev *pdev, dma64_addr_t dma_addr, size_t len, int direction)
83{
84}
85
86static inline void
87pci_dac_dma_sync_single_for_device(struct pci_dev *pdev, dma64_addr_t dma_addr, size_t len, int direction)
88{
89 flush_write_buffers();
90}
91
92#define HAVE_PCI_MMAP 59#define HAVE_PCI_MMAP
93extern int pci_mmap_page_range(struct pci_dev *dev, struct vm_area_struct *vma, 60extern int pci_mmap_page_range(struct pci_dev *dev, struct vm_area_struct *vma,
94 enum pci_mmap_state mmap_state, int write_combine); 61 enum pci_mmap_state mmap_state, int write_combine);
diff --git a/include/asm-ia64/pci.h b/include/asm-ia64/pci.h
index 26b69280f6c7..3523d2584598 100644
--- a/include/asm-ia64/pci.h
+++ b/include/asm-ia64/pci.h
@@ -71,14 +71,6 @@ pcibios_penalize_isa_irq (int irq, int active)
71#define pci_unmap_len_set(PTR, LEN_NAME, VAL) \ 71#define pci_unmap_len_set(PTR, LEN_NAME, VAL) \
72 (((PTR)->LEN_NAME) = (VAL)) 72 (((PTR)->LEN_NAME) = (VAL))
73 73
74/* The ia64 platform always supports 64-bit addressing. */
75#define pci_dac_dma_supported(pci_dev, mask) (1)
76#define pci_dac_page_to_dma(dev,pg,off,dir) ((dma_addr_t) page_to_bus(pg) + (off))
77#define pci_dac_dma_to_page(dev,dma_addr) (virt_to_page(bus_to_virt(dma_addr)))
78#define pci_dac_dma_to_offset(dev,dma_addr) offset_in_page(dma_addr)
79#define pci_dac_dma_sync_single_for_cpu(dev,dma_addr,len,dir) do { } while (0)
80#define pci_dac_dma_sync_single_for_device(dev,dma_addr,len,dir) do { mb(); } while (0)
81
82#ifdef CONFIG_PCI 74#ifdef CONFIG_PCI
83static inline void pci_dma_burst_advice(struct pci_dev *pdev, 75static inline void pci_dma_burst_advice(struct pci_dev *pdev,
84 enum pci_dma_burst_strategy *strat, 76 enum pci_dma_burst_strategy *strat,
diff --git a/include/asm-m68knommu/pci.h b/include/asm-m68knommu/pci.h
index a99ce768f4a6..a13f3cc87451 100644
--- a/include/asm-m68knommu/pci.h
+++ b/include/asm-m68knommu/pci.h
@@ -24,12 +24,6 @@ static inline int pci_dma_supported(struct pci_dev *hwdev, u64 mask)
24 return 1; 24 return 1;
25} 25}
26 26
27/*
28 * Not supporting more than 32-bit PCI bus addresses now, but
29 * must satisfy references to this function. Change if needed.
30 */
31#define pci_dac_dma_supported(pci_dev, mask) (0)
32
33#endif /* CONFIG_COMEMPCI */ 27#endif /* CONFIG_COMEMPCI */
34 28
35#endif /* M68KNOMMU_PCI_H */ 29#endif /* M68KNOMMU_PCI_H */
diff --git a/include/asm-mips/pci.h b/include/asm-mips/pci.h
index 6e8c5540bd27..4fcc185cb2d1 100644
--- a/include/asm-mips/pci.h
+++ b/include/asm-mips/pci.h
@@ -121,20 +121,6 @@ extern unsigned int PCI_DMA_BUS_IS_PHYS;
121 121
122#endif /* CONFIG_DMA_NEED_PCI_MAP_STATE */ 122#endif /* CONFIG_DMA_NEED_PCI_MAP_STATE */
123 123
124/* This is always fine. */
125#define pci_dac_dma_supported(pci_dev, mask) (1)
126
127extern dma64_addr_t pci_dac_page_to_dma(struct pci_dev *pdev,
128 struct page *page, unsigned long offset, int direction);
129extern struct page *pci_dac_dma_to_page(struct pci_dev *pdev,
130 dma64_addr_t dma_addr);
131extern unsigned long pci_dac_dma_to_offset(struct pci_dev *pdev,
132 dma64_addr_t dma_addr);
133extern void pci_dac_dma_sync_single_for_cpu(struct pci_dev *pdev,
134 dma64_addr_t dma_addr, size_t len, int direction);
135extern void pci_dac_dma_sync_single_for_device(struct pci_dev *pdev,
136 dma64_addr_t dma_addr, size_t len, int direction);
137
138#ifdef CONFIG_PCI 124#ifdef CONFIG_PCI
139static inline void pci_dma_burst_advice(struct pci_dev *pdev, 125static inline void pci_dma_burst_advice(struct pci_dev *pdev,
140 enum pci_dma_burst_strategy *strat, 126 enum pci_dma_burst_strategy *strat,
diff --git a/include/asm-parisc/pci.h b/include/asm-parisc/pci.h
index c331d49e4584..61fbd57a8323 100644
--- a/include/asm-parisc/pci.h
+++ b/include/asm-parisc/pci.h
@@ -238,9 +238,6 @@ extern inline void pcibios_register_hba(struct pci_hba_data *x)
238#define PCIBIOS_MIN_IO 0x10 238#define PCIBIOS_MIN_IO 0x10
239#define PCIBIOS_MIN_MEM 0x1000 /* NBPG - but pci/setup-res.c dies */ 239#define PCIBIOS_MIN_MEM 0x1000 /* NBPG - but pci/setup-res.c dies */
240 240
241/* Don't support DAC yet. */
242#define pci_dac_dma_supported(pci_dev, mask) (0)
243
244/* export the pci_ DMA API in terms of the dma_ one */ 241/* export the pci_ DMA API in terms of the dma_ one */
245#include <asm-generic/pci-dma-compat.h> 242#include <asm-generic/pci-dma-compat.h>
246 243
diff --git a/include/asm-powerpc/dma-mapping.h b/include/asm-powerpc/dma-mapping.h
index a19a6f1a1cf1..f6bd804d9090 100644
--- a/include/asm-powerpc/dma-mapping.h
+++ b/include/asm-powerpc/dma-mapping.h
@@ -61,7 +61,6 @@ struct dma_mapping_ops {
61 void (*unmap_sg)(struct device *dev, struct scatterlist *sg, 61 void (*unmap_sg)(struct device *dev, struct scatterlist *sg,
62 int nents, enum dma_data_direction direction); 62 int nents, enum dma_data_direction direction);
63 int (*dma_supported)(struct device *dev, u64 mask); 63 int (*dma_supported)(struct device *dev, u64 mask);
64 int (*dac_dma_supported)(struct device *dev, u64 mask);
65 int (*set_dma_mask)(struct device *dev, u64 dma_mask); 64 int (*set_dma_mask)(struct device *dev, u64 dma_mask);
66}; 65};
67 66
diff --git a/include/asm-powerpc/pci.h b/include/asm-powerpc/pci.h
index b36a284bedf3..e16e7bc9ab5c 100644
--- a/include/asm-powerpc/pci.h
+++ b/include/asm-powerpc/pci.h
@@ -74,18 +74,6 @@ static inline int pci_get_legacy_ide_irq(struct pci_dev *dev, int channel)
74extern void set_pci_dma_ops(struct dma_mapping_ops *dma_ops); 74extern void set_pci_dma_ops(struct dma_mapping_ops *dma_ops);
75extern struct dma_mapping_ops *get_pci_dma_ops(void); 75extern struct dma_mapping_ops *get_pci_dma_ops(void);
76 76
77/* For DAC DMA, we currently don't support it by default, but
78 * we let 64-bit platforms override this.
79 */
80static inline int pci_dac_dma_supported(struct pci_dev *hwdev,u64 mask)
81{
82 struct dma_mapping_ops *d = get_pci_dma_ops();
83
84 if (d && d->dac_dma_supported)
85 return d->dac_dma_supported(&hwdev->dev, mask);
86 return 0;
87}
88
89static inline void pci_dma_burst_advice(struct pci_dev *pdev, 77static inline void pci_dma_burst_advice(struct pci_dev *pdev,
90 enum pci_dma_burst_strategy *strat, 78 enum pci_dma_burst_strategy *strat,
91 unsigned long *strategy_parameter) 79 unsigned long *strategy_parameter)
@@ -124,12 +112,6 @@ static inline void pci_dma_burst_advice(struct pci_dev *pdev,
124} 112}
125#endif 113#endif
126 114
127/*
128 * At present there are very few 32-bit PPC machines that can have
129 * memory above the 4GB point, and we don't support that.
130 */
131#define pci_dac_dma_supported(pci_dev, mask) (0)
132
133/* Return the index of the PCI controller for device PDEV. */ 115/* Return the index of the PCI controller for device PDEV. */
134#define pci_domain_nr(bus) ((struct pci_controller *)(bus)->sysdata)->index 116#define pci_domain_nr(bus) ((struct pci_controller *)(bus)->sysdata)->index
135 117
diff --git a/include/asm-ppc/pci.h b/include/asm-ppc/pci.h
index 0a66a6f1059a..d2442cd72a59 100644
--- a/include/asm-ppc/pci.h
+++ b/include/asm-ppc/pci.h
@@ -102,12 +102,6 @@ static inline void pci_dma_burst_advice(struct pci_dev *pdev,
102} 102}
103#endif 103#endif
104 104
105/*
106 * At present there are very few 32-bit PPC machines that can have
107 * memory above the 4GB point, and we don't support that.
108 */
109#define pci_dac_dma_supported(pci_dev, mask) (0)
110
111/* Return the index of the PCI controller for device PDEV. */ 105/* Return the index of the PCI controller for device PDEV. */
112#define pci_domain_nr(bus) ((struct pci_controller *)(bus)->sysdata)->index 106#define pci_domain_nr(bus) ((struct pci_controller *)(bus)->sysdata)->index
113 107
diff --git a/include/asm-sh/pci.h b/include/asm-sh/pci.h
index 6f741f3a5d45..2757ce096ff7 100644
--- a/include/asm-sh/pci.h
+++ b/include/asm-sh/pci.h
@@ -110,11 +110,6 @@ static inline void pcibios_penalize_isa_irq(int irq, int active)
110#define pci_unmap_len_set(PTR, LEN_NAME, VAL) do { } while (0) 110#define pci_unmap_len_set(PTR, LEN_NAME, VAL) do { } while (0)
111#endif 111#endif
112 112
113/* Not supporting more than 32-bit PCI bus addresses now, but
114 * must satisfy references to this function. Change if needed.
115 */
116#define pci_dac_dma_supported(pci_dev, mask) (0)
117
118#ifdef CONFIG_PCI 113#ifdef CONFIG_PCI
119static inline void pci_dma_burst_advice(struct pci_dev *pdev, 114static inline void pci_dma_burst_advice(struct pci_dev *pdev,
120 enum pci_dma_burst_strategy *strat, 115 enum pci_dma_burst_strategy *strat,
diff --git a/include/asm-sh64/pci.h b/include/asm-sh64/pci.h
index 0a2b2bd48b87..57a67cf7a5c4 100644
--- a/include/asm-sh64/pci.h
+++ b/include/asm-sh64/pci.h
@@ -72,11 +72,6 @@ static inline void pcibios_penalize_isa_irq(int irq, int active)
72#define pci_unmap_len_set(PTR, LEN_NAME, VAL) do { } while (0) 72#define pci_unmap_len_set(PTR, LEN_NAME, VAL) do { } while (0)
73#endif 73#endif
74 74
75/* Not supporting more than 32-bit PCI bus addresses now, but
76 * must satisfy references to this function. Change if needed.
77 */
78#define pci_dac_dma_supported(pci_dev, mask) (0)
79
80/* These macros should be used after a pci_map_sg call has been done 75/* These macros should be used after a pci_map_sg call has been done
81 * to get bus addresses of each of the SG entries and their lengths. 76 * to get bus addresses of each of the SG entries and their lengths.
82 * You should only work with the number of sg entries pci_map_sg 77 * You should only work with the number of sg entries pci_map_sg
diff --git a/include/asm-sparc/pci.h b/include/asm-sparc/pci.h
index a1ff7acc7644..b93b6c79e08f 100644
--- a/include/asm-sparc/pci.h
+++ b/include/asm-sparc/pci.h
@@ -142,8 +142,6 @@ static inline int pci_dma_supported(struct pci_dev *hwdev, u64 mask)
142 return 1; 142 return 1;
143} 143}
144 144
145#define pci_dac_dma_supported(dev, mask) (0)
146
147#ifdef CONFIG_PCI 145#ifdef CONFIG_PCI
148static inline void pci_dma_burst_advice(struct pci_dev *pdev, 146static inline void pci_dma_burst_advice(struct pci_dev *pdev,
149 enum pci_dma_burst_strategy *strat, 147 enum pci_dma_burst_strategy *strat,
diff --git a/include/asm-sparc64/pci.h b/include/asm-sparc64/pci.h
index 202915d82759..e11ac100f043 100644
--- a/include/asm-sparc64/pci.h
+++ b/include/asm-sparc64/pci.h
@@ -206,49 +206,6 @@ extern int pci_dma_supported(struct pci_dev *hwdev, u64 mask);
206#define PCI64_REQUIRED_MASK (~(dma64_addr_t)0) 206#define PCI64_REQUIRED_MASK (~(dma64_addr_t)0)
207#define PCI64_ADDR_BASE 0xfffc000000000000UL 207#define PCI64_ADDR_BASE 0xfffc000000000000UL
208 208
209/* Usage of the pci_dac_foo interfaces is only valid if this
210 * test passes.
211 */
212#define pci_dac_dma_supported(pci_dev, mask) \
213 ((((mask) & PCI64_REQUIRED_MASK) == PCI64_REQUIRED_MASK) ? 1 : 0)
214
215static inline dma64_addr_t
216pci_dac_page_to_dma(struct pci_dev *pdev, struct page *page, unsigned long offset, int direction)
217{
218 return (PCI64_ADDR_BASE +
219 __pa(page_address(page)) + offset);
220}
221
222static inline struct page *
223pci_dac_dma_to_page(struct pci_dev *pdev, dma64_addr_t dma_addr)
224{
225 unsigned long paddr = (dma_addr & PAGE_MASK) - PCI64_ADDR_BASE;
226
227 return virt_to_page(__va(paddr));
228}
229
230static inline unsigned long
231pci_dac_dma_to_offset(struct pci_dev *pdev, dma64_addr_t dma_addr)
232{
233 return (dma_addr & ~PAGE_MASK);
234}
235
236static inline void
237pci_dac_dma_sync_single_for_cpu(struct pci_dev *pdev, dma64_addr_t dma_addr, size_t len, int direction)
238{
239 /* DAC cycle addressing does not make use of the
240 * PCI controller's streaming cache, so nothing to do.
241 */
242}
243
244static inline void
245pci_dac_dma_sync_single_for_device(struct pci_dev *pdev, dma64_addr_t dma_addr, size_t len, int direction)
246{
247 /* DAC cycle addressing does not make use of the
248 * PCI controller's streaming cache, so nothing to do.
249 */
250}
251
252#define PCI_DMA_ERROR_CODE (~(dma_addr_t)0x0) 209#define PCI_DMA_ERROR_CODE (~(dma_addr_t)0x0)
253 210
254static inline int pci_dma_mapping_error(dma_addr_t dma_addr) 211static inline int pci_dma_mapping_error(dma_addr_t dma_addr)
diff --git a/include/asm-v850/rte_cb.h b/include/asm-v850/rte_cb.h
index 9f7f02cb0391..e85d261b79bf 100644
--- a/include/asm-v850/rte_cb.h
+++ b/include/asm-v850/rte_cb.h
@@ -64,7 +64,6 @@
64/* As we don't really support PCI DMA to cpu memory, and use bounce-buffers 64/* As we don't really support PCI DMA to cpu memory, and use bounce-buffers
65 instead, perversely enough, this becomes always true! */ 65 instead, perversely enough, this becomes always true! */
66# define pci_dma_supported(dev, mask) 1 66# define pci_dma_supported(dev, mask) 1
67# define pci_dac_dma_supported(dev, mask) 0
68# define pcibios_assign_all_busses() 1 67# define pcibios_assign_all_busses() 1
69 68
70#endif /* CONFIG_RTE_MB_A_PCI */ 69#endif /* CONFIG_RTE_MB_A_PCI */
diff --git a/include/asm-x86_64/pci.h b/include/asm-x86_64/pci.h
index d95c9e78fe1d..bda94fd5176f 100644
--- a/include/asm-x86_64/pci.h
+++ b/include/asm-x86_64/pci.h
@@ -54,14 +54,6 @@ extern int iommu_setup(char *opt);
54 54
55#if defined(CONFIG_IOMMU) || defined(CONFIG_CALGARY_IOMMU) 55#if defined(CONFIG_IOMMU) || defined(CONFIG_CALGARY_IOMMU)
56 56
57/*
58 * x86-64 always supports DAC, but sometimes it is useful to force
59 * devices through the IOMMU to get automatic sg list merging.
60 * Optional right now.
61 */
62extern int iommu_sac_force;
63#define pci_dac_dma_supported(pci_dev, mask) (!iommu_sac_force)
64
65#define DECLARE_PCI_UNMAP_ADDR(ADDR_NAME) \ 57#define DECLARE_PCI_UNMAP_ADDR(ADDR_NAME) \
66 dma_addr_t ADDR_NAME; 58 dma_addr_t ADDR_NAME;
67#define DECLARE_PCI_UNMAP_LEN(LEN_NAME) \ 59#define DECLARE_PCI_UNMAP_LEN(LEN_NAME) \
@@ -78,8 +70,6 @@ extern int iommu_sac_force;
78#else 70#else
79/* No IOMMU */ 71/* No IOMMU */
80 72
81#define pci_dac_dma_supported(pci_dev, mask) 1
82
83#define DECLARE_PCI_UNMAP_ADDR(ADDR_NAME) 73#define DECLARE_PCI_UNMAP_ADDR(ADDR_NAME)
84#define DECLARE_PCI_UNMAP_LEN(LEN_NAME) 74#define DECLARE_PCI_UNMAP_LEN(LEN_NAME)
85#define pci_unmap_addr(PTR, ADDR_NAME) (0) 75#define pci_unmap_addr(PTR, ADDR_NAME) (0)
@@ -91,36 +81,6 @@ extern int iommu_sac_force;
91 81
92#include <asm-generic/pci-dma-compat.h> 82#include <asm-generic/pci-dma-compat.h>
93 83
94static inline dma64_addr_t
95pci_dac_page_to_dma(struct pci_dev *pdev, struct page *page, unsigned long offset, int direction)
96{
97 return ((dma64_addr_t) page_to_phys(page) +
98 (dma64_addr_t) offset);
99}
100
101static inline struct page *
102pci_dac_dma_to_page(struct pci_dev *pdev, dma64_addr_t dma_addr)
103{
104 return virt_to_page(__va(dma_addr));
105}
106
107static inline unsigned long
108pci_dac_dma_to_offset(struct pci_dev *pdev, dma64_addr_t dma_addr)
109{
110 return (dma_addr & ~PAGE_MASK);
111}
112
113static inline void
114pci_dac_dma_sync_single_for_cpu(struct pci_dev *pdev, dma64_addr_t dma_addr, size_t len, int direction)
115{
116}
117
118static inline void
119pci_dac_dma_sync_single_for_device(struct pci_dev *pdev, dma64_addr_t dma_addr, size_t len, int direction)
120{
121 flush_write_buffers();
122}
123
124#ifdef CONFIG_PCI 84#ifdef CONFIG_PCI
125static inline void pci_dma_burst_advice(struct pci_dev *pdev, 85static inline void pci_dma_burst_advice(struct pci_dev *pdev,
126 enum pci_dma_burst_strategy *strat, 86 enum pci_dma_burst_strategy *strat,
diff --git a/include/asm-xtensa/pci.h b/include/asm-xtensa/pci.h
index 644411c8e0ca..66410acf18b4 100644
--- a/include/asm-xtensa/pci.h
+++ b/include/asm-xtensa/pci.h
@@ -64,9 +64,6 @@ struct pci_dev;
64#define pci_ubnmap_len(PTR, LEN_NAME) (0) 64#define pci_ubnmap_len(PTR, LEN_NAME) (0)
65#define pci_unmap_len_set(PTR, LEN_NAME, VAL) do { } while (0) 65#define pci_unmap_len_set(PTR, LEN_NAME, VAL) do { } while (0)
66 66
67/* We cannot access memory above 4GB */
68#define pci_dac_dma_supported(pci_dev, mask) (0)
69
70/* Map a range of PCI memory or I/O space for a device into user space */ 67/* Map a range of PCI memory or I/O space for a device into user space */
71int pci_mmap_page_range(struct pci_dev *pdev, struct vm_area_struct *vma, 68int pci_mmap_page_range(struct pci_dev *pdev, struct vm_area_struct *vma,
72 enum pci_mmap_state mmap_state, int write_combine); 69 enum pci_mmap_state mmap_state, int write_combine);