• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /****************************************************************************
2  ****************************************************************************
3  ***
4  ***   This header was automatically generated from a Linux kernel header
5  ***   of the same name, to make information necessary for userspace to
6  ***   call into the kernel available to libc.  It contains only constants,
7  ***   structures, and macros generated from the original header, and thus,
8  ***   contains no copyrightable information.
9  ***
10  ****************************************************************************
11  ****************************************************************************/
12 #ifndef _ASM_LINUX_DMA_MAPPING_H
13 #define _ASM_LINUX_DMA_MAPPING_H
14 
15 #include <linux/device.h>
16 #include <linux/err.h>
17 
18 enum dma_data_direction {
19  DMA_BIDIRECTIONAL = 0,
20  DMA_TO_DEVICE = 1,
21  DMA_FROM_DEVICE = 2,
22  DMA_NONE = 3,
23 };
24 
25 #define DMA_64BIT_MASK 0xffffffffffffffffULL
26 #define DMA_48BIT_MASK 0x0000ffffffffffffULL
27 #define DMA_40BIT_MASK 0x000000ffffffffffULL
28 #define DMA_39BIT_MASK 0x0000007fffffffffULL
29 #define DMA_32BIT_MASK 0x00000000ffffffffULL
30 #define DMA_31BIT_MASK 0x000000007fffffffULL
31 #define DMA_30BIT_MASK 0x000000003fffffffULL
32 #define DMA_29BIT_MASK 0x000000001fffffffULL
33 #define DMA_28BIT_MASK 0x000000000fffffffULL
34 #define DMA_24BIT_MASK 0x0000000000ffffffULL
35 
36 #include <asm/dma-mapping.h>
37 
38 #define dma_sync_single dma_sync_single_for_cpu
39 #define dma_sync_sg dma_sync_sg_for_cpu
40 
41 #define DMA_MEMORY_MAP 0x01
42 #define DMA_MEMORY_IO 0x02
43 #define DMA_MEMORY_INCLUDES_CHILDREN 0x04
44 #define DMA_MEMORY_EXCLUSIVE 0x08
45 
46 #ifndef ARCH_HAS_DMA_DECLARE_COHERENT_MEMORY
47 #endif
48 #endif
49