direct-io.hg

view linux-2.6-xen-sparse/include/asm-i386/mach-xen/asm/swiotlb.h @ 11509:2e6c10dc7c0b

[POWERPC][XEN] make sure put_domain() is called in case of allocate_rma() failuer

Signed-off-by: Jimi Xenidis <jimix@watson.ibm.com>
Signed-off-by: Hollis Blanchard <hollisb@us.ibm.com>
author Jimi Xenidis <jimix@watson.ibm.com>
date Tue Sep 12 10:53:46 2006 -0400 (2006-09-12)
parents c53a9a3be3f7
children 301bcae16928
line source
1 #ifndef _ASM_SWIOTLB_H
2 #define _ASM_SWIOTLB_H 1
4 #include <linux/config.h>
6 /* SWIOTLB interface */
8 extern dma_addr_t swiotlb_map_single(struct device *hwdev, void *ptr, size_t size,
9 int dir);
10 extern void swiotlb_unmap_single(struct device *hwdev, dma_addr_t dev_addr,
11 size_t size, int dir);
12 extern void swiotlb_sync_single_for_cpu(struct device *hwdev,
13 dma_addr_t dev_addr,
14 size_t size, int dir);
15 extern void swiotlb_sync_single_for_device(struct device *hwdev,
16 dma_addr_t dev_addr,
17 size_t size, int dir);
18 extern void swiotlb_sync_sg_for_cpu(struct device *hwdev,
19 struct scatterlist *sg, int nelems,
20 int dir);
21 extern void swiotlb_sync_sg_for_device(struct device *hwdev,
22 struct scatterlist *sg, int nelems,
23 int dir);
24 extern int swiotlb_map_sg(struct device *hwdev, struct scatterlist *sg,
25 int nents, int direction);
26 extern void swiotlb_unmap_sg(struct device *hwdev, struct scatterlist *sg,
27 int nents, int direction);
28 extern int swiotlb_dma_mapping_error(dma_addr_t dma_addr);
29 extern dma_addr_t swiotlb_map_page(struct device *hwdev, struct page *page,
30 unsigned long offset, size_t size,
31 enum dma_data_direction direction);
32 extern void swiotlb_unmap_page(struct device *hwdev, dma_addr_t dma_address,
33 size_t size, enum dma_data_direction direction);
34 extern int swiotlb_dma_supported(struct device *hwdev, u64 mask);
35 extern void swiotlb_init(void);
37 #ifdef CONFIG_SWIOTLB
38 extern int swiotlb;
39 #else
40 #define swiotlb 0
41 #endif
43 #endif