]> pilppa.org Git - linux-2.6-omap-h63xx.git/blob - include/asm-x86/dma-mapping_32.h
fd7246dddad4729ddf6f2696cada9eded99f8169
[linux-2.6-omap-h63xx.git] / include / asm-x86 / dma-mapping_32.h
1 #ifndef _ASM_I386_DMA_MAPPING_H
2 #define _ASM_I386_DMA_MAPPING_H
3
4 #include <linux/mm.h>
5 #include <linux/scatterlist.h>
6
7 #include <asm/cache.h>
8 #include <asm/io.h>
9 #include <asm/bug.h>
10
11 static inline int
12 dma_mapping_error(dma_addr_t dma_addr)
13 {
14         return 0;
15 }
16
17 extern int forbid_dac;
18
19 static inline int
20 dma_get_cache_alignment(void)
21 {
22         /* no easy way to get cache size on all x86, so return the
23          * maximum possible, to be safe */
24         return (1 << INTERNODE_CACHE_SHIFT);
25 }
26
27 #define dma_is_consistent(d, h) (1)
28
29 #define ARCH_HAS_DMA_DECLARE_COHERENT_MEMORY
30 extern int
31 dma_declare_coherent_memory(struct device *dev, dma_addr_t bus_addr,
32                             dma_addr_t device_addr, size_t size, int flags);
33
34 extern void
35 dma_release_declared_memory(struct device *dev);
36
37 extern void *
38 dma_mark_declared_memory_occupied(struct device *dev,
39                                   dma_addr_t device_addr, size_t size);
40
41 #endif