diff options
-rw-r--r-- | arch/x86/kernel/pci-dma_32.c | 4 | ||||
-rw-r--r-- | include/asm-x86/dma-mapping.h | 2 | ||||
-rw-r--r-- | include/asm-x86/dma-mapping_64.h | 1 |
3 files changed, 6 insertions, 1 deletions
diff --git a/arch/x86/kernel/pci-dma_32.c b/arch/x86/kernel/pci-dma_32.c index 453b4bda271..55ab3c874d8 100644 --- a/arch/x86/kernel/pci-dma_32.c +++ b/arch/x86/kernel/pci-dma_32.c | |||
@@ -14,6 +14,10 @@ | |||
14 | #include <linux/module.h> | 14 | #include <linux/module.h> |
15 | #include <asm/io.h> | 15 | #include <asm/io.h> |
16 | 16 | ||
17 | /* For i386, we make it point to the NULL address */ | ||
18 | dma_addr_t bad_dma_address __read_mostly = 0x0; | ||
19 | EXPORT_SYMBOL(bad_dma_address); | ||
20 | |||
17 | struct dma_coherent_mem { | 21 | struct dma_coherent_mem { |
18 | void *virt_base; | 22 | void *virt_base; |
19 | u32 device_base; | 23 | u32 device_base; |
diff --git a/include/asm-x86/dma-mapping.h b/include/asm-x86/dma-mapping.h index c671a0aea59..984935d86bb 100644 --- a/include/asm-x86/dma-mapping.h +++ b/include/asm-x86/dma-mapping.h | |||
@@ -10,6 +10,8 @@ | |||
10 | #include <asm/io.h> | 10 | #include <asm/io.h> |
11 | #include <asm/swiotlb.h> | 11 | #include <asm/swiotlb.h> |
12 | 12 | ||
13 | extern dma_addr_t bad_dma_address; | ||
14 | |||
13 | struct dma_mapping_ops { | 15 | struct dma_mapping_ops { |
14 | int (*mapping_error)(dma_addr_t dma_addr); | 16 | int (*mapping_error)(dma_addr_t dma_addr); |
15 | void* (*alloc_coherent)(struct device *dev, size_t size, | 17 | void* (*alloc_coherent)(struct device *dev, size_t size, |
diff --git a/include/asm-x86/dma-mapping_64.h b/include/asm-x86/dma-mapping_64.h index 9674dac9fa3..352bf4164a5 100644 --- a/include/asm-x86/dma-mapping_64.h +++ b/include/asm-x86/dma-mapping_64.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _X8664_DMA_MAPPING_H | 1 | #ifndef _X8664_DMA_MAPPING_H |
2 | #define _X8664_DMA_MAPPING_H 1 | 2 | #define _X8664_DMA_MAPPING_H 1 |
3 | 3 | ||
4 | extern dma_addr_t bad_dma_address; | ||
5 | extern int iommu_merge; | 4 | extern int iommu_merge; |
6 | 5 | ||
7 | static inline int dma_mapping_error(dma_addr_t dma_addr) | 6 | static inline int dma_mapping_error(dma_addr_t dma_addr) |