diff options
author | FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> | 2009-01-05 09:59:02 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-01-06 08:06:57 -0500 |
commit | 160c1d8e40866edfeae7d68816b7005d70acf391 (patch) | |
tree | 37dd78b2ea28a3953a46d401bd9657005eb444d7 /include/linux/swiotlb.h | |
parent | f0402a262e1a4c03fc66b83659823bdcaac3c41a (diff) |
x86, ia64: convert to use generic dma_map_ops struct
This converts X86 and IA64 to use include/linux/dma-mapping.h.
It's a bit large but pretty boring. The major change for X86 is
converting 'int dir' to 'enum dma_data_direction dir' in DMA mapping
operations. The major changes for IA64 is using map_page and
unmap_page instead of map_single and unmap_single.
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Acked-by: Tony Luck <tony.luck@intel.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include/linux/swiotlb.h')
-rw-r--r-- | include/linux/swiotlb.h | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/include/linux/swiotlb.h b/include/linux/swiotlb.h index dedd3c0cfe30..0567c3d8633b 100644 --- a/include/linux/swiotlb.h +++ b/include/linux/swiotlb.h | |||
@@ -66,36 +66,38 @@ swiotlb_unmap_sg(struct device *hwdev, struct scatterlist *sg, int nents, | |||
66 | 66 | ||
67 | extern int | 67 | extern int |
68 | swiotlb_map_sg_attrs(struct device *hwdev, struct scatterlist *sgl, int nelems, | 68 | swiotlb_map_sg_attrs(struct device *hwdev, struct scatterlist *sgl, int nelems, |
69 | int dir, struct dma_attrs *attrs); | 69 | enum dma_data_direction dir, struct dma_attrs *attrs); |
70 | 70 | ||
71 | extern void | 71 | extern void |
72 | swiotlb_unmap_sg_attrs(struct device *hwdev, struct scatterlist *sgl, | 72 | swiotlb_unmap_sg_attrs(struct device *hwdev, struct scatterlist *sgl, |
73 | int nelems, int dir, struct dma_attrs *attrs); | 73 | int nelems, enum dma_data_direction dir, |
74 | struct dma_attrs *attrs); | ||
74 | 75 | ||
75 | extern void | 76 | extern void |
76 | swiotlb_sync_single_for_cpu(struct device *hwdev, dma_addr_t dev_addr, | 77 | swiotlb_sync_single_for_cpu(struct device *hwdev, dma_addr_t dev_addr, |
77 | size_t size, int dir); | 78 | size_t size, enum dma_data_direction dir); |
78 | 79 | ||
79 | extern void | 80 | extern void |
80 | swiotlb_sync_sg_for_cpu(struct device *hwdev, struct scatterlist *sg, | 81 | swiotlb_sync_sg_for_cpu(struct device *hwdev, struct scatterlist *sg, |
81 | int nelems, int dir); | 82 | int nelems, enum dma_data_direction dir); |
82 | 83 | ||
83 | extern void | 84 | extern void |
84 | swiotlb_sync_single_for_device(struct device *hwdev, dma_addr_t dev_addr, | 85 | swiotlb_sync_single_for_device(struct device *hwdev, dma_addr_t dev_addr, |
85 | size_t size, int dir); | 86 | size_t size, enum dma_data_direction dir); |
86 | 87 | ||
87 | extern void | 88 | extern void |
88 | swiotlb_sync_sg_for_device(struct device *hwdev, struct scatterlist *sg, | 89 | swiotlb_sync_sg_for_device(struct device *hwdev, struct scatterlist *sg, |
89 | int nelems, int dir); | 90 | int nelems, enum dma_data_direction dir); |
90 | 91 | ||
91 | extern void | 92 | extern void |
92 | swiotlb_sync_single_range_for_cpu(struct device *hwdev, dma_addr_t dev_addr, | 93 | swiotlb_sync_single_range_for_cpu(struct device *hwdev, dma_addr_t dev_addr, |
93 | unsigned long offset, size_t size, int dir); | 94 | unsigned long offset, size_t size, |
95 | enum dma_data_direction dir); | ||
94 | 96 | ||
95 | extern void | 97 | extern void |
96 | swiotlb_sync_single_range_for_device(struct device *hwdev, dma_addr_t dev_addr, | 98 | swiotlb_sync_single_range_for_device(struct device *hwdev, dma_addr_t dev_addr, |
97 | unsigned long offset, size_t size, | 99 | unsigned long offset, size_t size, |
98 | int dir); | 100 | enum dma_data_direction dir); |
99 | 101 | ||
100 | extern int | 102 | extern int |
101 | swiotlb_dma_mapping_error(struct device *hwdev, dma_addr_t dma_addr); | 103 | swiotlb_dma_mapping_error(struct device *hwdev, dma_addr_t dma_addr); |