diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2008-01-30 07:30:21 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-01-30 07:30:21 -0500 |
commit | 3ebc51d7c95425c3b4667fa042576fb1c6e2ea16 (patch) | |
tree | 0d63faa0c3df10c1e55264e807b88ef844262fc0 | |
parent | f28b8d608829aecd7343015a0df89f6b6e89d391 (diff) |
x86: merge include/asm-x86/scatterlist.h
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
-rw-r--r-- | include/asm-x86/scatterlist.h | 34 | ||||
-rw-r--r-- | include/asm-x86/scatterlist_32.h | 28 | ||||
-rw-r--r-- | include/asm-x86/scatterlist_64.h | 29 |
3 files changed, 32 insertions, 59 deletions
diff --git a/include/asm-x86/scatterlist.h b/include/asm-x86/scatterlist.h index 3a1e76257a27..d13c197866d6 100644 --- a/include/asm-x86/scatterlist.h +++ b/include/asm-x86/scatterlist.h | |||
@@ -1,5 +1,35 @@ | |||
1 | #ifndef _ASM_X86_SCATTERLIST_H | ||
2 | #define _ASM_X86_SCATTERLIST_H | ||
3 | |||
4 | #include <asm/types.h> | ||
5 | |||
6 | struct scatterlist { | ||
7 | #ifdef CONFIG_DEBUG_SG | ||
8 | unsigned long sg_magic; | ||
9 | #endif | ||
10 | unsigned long page_link; | ||
11 | unsigned int offset; | ||
12 | unsigned int length; | ||
13 | dma_addr_t dma_address; | ||
14 | #ifdef CONFIG_X86_64 | ||
15 | unsigned int dma_length; | ||
16 | #endif | ||
17 | }; | ||
18 | |||
19 | #define ARCH_HAS_SG_CHAIN | ||
20 | #define ISA_DMA_THRESHOLD (0x00ffffff) | ||
21 | |||
22 | /* | ||
23 | * These macros should be used after a pci_map_sg call has been done | ||
24 | * to get bus addresses of each of the SG entries and their lengths. | ||
25 | * You should only work with the number of sg entries pci_map_sg | ||
26 | * returns. | ||
27 | */ | ||
28 | #define sg_dma_address(sg) ((sg)->dma_address) | ||
1 | #ifdef CONFIG_X86_32 | 29 | #ifdef CONFIG_X86_32 |
2 | # include "scatterlist_32.h" | 30 | # define sg_dma_len(sg) ((sg)->length) |
3 | #else | 31 | #else |
4 | # include "scatterlist_64.h" | 32 | # define sg_dma_len(sg) ((sg)->dma_length) |
33 | #endif | ||
34 | |||
5 | #endif | 35 | #endif |
diff --git a/include/asm-x86/scatterlist_32.h b/include/asm-x86/scatterlist_32.h deleted file mode 100644 index 0e7d997a34be..000000000000 --- a/include/asm-x86/scatterlist_32.h +++ /dev/null | |||
@@ -1,28 +0,0 @@ | |||
1 | #ifndef _I386_SCATTERLIST_H | ||
2 | #define _I386_SCATTERLIST_H | ||
3 | |||
4 | #include <asm/types.h> | ||
5 | |||
6 | struct scatterlist { | ||
7 | #ifdef CONFIG_DEBUG_SG | ||
8 | unsigned long sg_magic; | ||
9 | #endif | ||
10 | unsigned long page_link; | ||
11 | unsigned int offset; | ||
12 | dma_addr_t dma_address; | ||
13 | unsigned int length; | ||
14 | }; | ||
15 | |||
16 | #define ARCH_HAS_SG_CHAIN | ||
17 | |||
18 | /* These macros should be used after a pci_map_sg call has been done | ||
19 | * to get bus addresses of each of the SG entries and their lengths. | ||
20 | * You should only work with the number of sg entries pci_map_sg | ||
21 | * returns. | ||
22 | */ | ||
23 | #define sg_dma_address(sg) ((sg)->dma_address) | ||
24 | #define sg_dma_len(sg) ((sg)->length) | ||
25 | |||
26 | #define ISA_DMA_THRESHOLD (0x00ffffff) | ||
27 | |||
28 | #endif /* !(_I386_SCATTERLIST_H) */ | ||
diff --git a/include/asm-x86/scatterlist_64.h b/include/asm-x86/scatterlist_64.h deleted file mode 100644 index 1847c72befeb..000000000000 --- a/include/asm-x86/scatterlist_64.h +++ /dev/null | |||
@@ -1,29 +0,0 @@ | |||
1 | #ifndef _X8664_SCATTERLIST_H | ||
2 | #define _X8664_SCATTERLIST_H | ||
3 | |||
4 | #include <asm/types.h> | ||
5 | |||
6 | struct scatterlist { | ||
7 | #ifdef CONFIG_DEBUG_SG | ||
8 | unsigned long sg_magic; | ||
9 | #endif | ||
10 | unsigned long page_link; | ||
11 | unsigned int offset; | ||
12 | unsigned int length; | ||
13 | dma_addr_t dma_address; | ||
14 | unsigned int dma_length; | ||
15 | }; | ||
16 | |||
17 | #define ARCH_HAS_SG_CHAIN | ||
18 | |||
19 | #define ISA_DMA_THRESHOLD (0x00ffffff) | ||
20 | |||
21 | /* These macros should be used after a pci_map_sg call has been done | ||
22 | * to get bus addresses of each of the SG entries and their lengths. | ||
23 | * You should only work with the number of sg entries pci_map_sg | ||
24 | * returns. | ||
25 | */ | ||
26 | #define sg_dma_address(sg) ((sg)->dma_address) | ||
27 | #define sg_dma_len(sg) ((sg)->dma_length) | ||
28 | |||
29 | #endif | ||