2ea88281161d0bb27b50c254b687aea3fe769036
[linux-flexiantxendom0-3.2.10.git] / include / asm-um / dma-mapping.h
1 #ifndef _ASM_DMA_MAPPING_H
2 #define _ASM_DMA_MAPPING_H
3
4 static inline int
5 dma_supported(struct device *dev, u64 mask)
6 {
7         BUG();
8         return(0);
9 }
10
11 static inline int
12 dma_set_mask(struct device *dev, u64 dma_mask)
13 {
14         BUG();
15         return(0);
16 }
17
18 static inline void *
19 dma_alloc_coherent(struct device *dev, size_t size, dma_addr_t *dma_handle,
20                    int flag)
21 {
22         BUG();
23         return((void *) 0);
24 }
25
26 static inline void
27 dma_free_coherent(struct device *dev, size_t size, void *cpu_addr,
28                   dma_addr_t dma_handle)
29 {
30         BUG();
31 }
32
33 static inline dma_addr_t
34 dma_map_single(struct device *dev, void *cpu_addr, size_t size,
35                enum dma_data_direction direction)
36 {
37         BUG();
38         return(0);
39 }
40
41 static inline void
42 dma_unmap_single(struct device *dev, dma_addr_t dma_addr, size_t size,
43                  enum dma_data_direction direction)
44 {
45         BUG();
46 }
47
48 static inline dma_addr_t
49 dma_map_page(struct device *dev, struct page *page,
50              unsigned long offset, size_t size,
51              enum dma_data_direction direction)
52 {
53         BUG();
54         return(0);
55 }
56
57 static inline void
58 dma_unmap_page(struct device *dev, dma_addr_t dma_address, size_t size,
59                enum dma_data_direction direction)
60 {
61         BUG();
62 }
63
64 static inline int
65 dma_map_sg(struct device *dev, struct scatterlist *sg, int nents,
66            enum dma_data_direction direction)
67 {
68         BUG();
69         return(0);
70 }
71
72 static inline void
73 dma_unmap_sg(struct device *dev, struct scatterlist *sg, int nhwentries,
74              enum dma_data_direction direction)
75 {
76         BUG();
77 }
78
79 static inline void
80 dma_sync_single(struct device *dev, dma_addr_t dma_handle, size_t size,
81                 enum dma_data_direction direction)
82 {
83         BUG();
84 }
85
86 static inline void
87 dma_sync_sg(struct device *dev, struct scatterlist *sg, int nelems,
88             enum dma_data_direction direction)
89 {
90         BUG();
91 }
92
93 #define dma_alloc_noncoherent(d, s, h, f) dma_alloc_coherent(d, s, h, f)
94 #define dma_free_noncoherent(d, s, v, h) dma_free_coherent(d, s, v, h)
95 #define dma_is_consistent(d) (1)
96
97 static inline int
98 dma_get_cache_alignment(void)
99 {
100         BUG();
101         return(0);
102 }
103
104 static inline void
105 dma_sync_single_range(struct device *dev, dma_addr_t dma_handle,
106                       unsigned long offset, size_t size,
107                       enum dma_data_direction direction)
108 {
109         BUG();
110 }
111
112 static inline void
113 dma_cache_sync(void *vaddr, size_t size,
114                enum dma_data_direction direction)
115 {
116         BUG();
117 }
118
119 #endif