diff options
-rw-r--r-- | arch/x86/kernel/pci-dma.c | 2 | ||||
-rw-r--r-- | include/asm-x86/swiotlb.h | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/arch/x86/kernel/pci-dma.c b/arch/x86/kernel/pci-dma.c index f16cbbe424a1..d12945de0565 100644 --- a/arch/x86/kernel/pci-dma.c +++ b/arch/x86/kernel/pci-dma.c | |||
@@ -122,9 +122,7 @@ void __init pci_iommu_alloc(void) | |||
122 | 122 | ||
123 | amd_iommu_detect(); | 123 | amd_iommu_detect(); |
124 | 124 | ||
125 | #ifdef CONFIG_SWIOTLB | ||
126 | pci_swiotlb_init(); | 125 | pci_swiotlb_init(); |
127 | #endif | ||
128 | } | 126 | } |
129 | #endif | 127 | #endif |
130 | 128 | ||
diff --git a/include/asm-x86/swiotlb.h b/include/asm-x86/swiotlb.h index f5d9e74b1e4a..c706a7442633 100644 --- a/include/asm-x86/swiotlb.h +++ b/include/asm-x86/swiotlb.h | |||
@@ -45,12 +45,14 @@ extern int swiotlb_force; | |||
45 | 45 | ||
46 | #ifdef CONFIG_SWIOTLB | 46 | #ifdef CONFIG_SWIOTLB |
47 | extern int swiotlb; | 47 | extern int swiotlb; |
48 | extern void pci_swiotlb_init(void); | ||
48 | #else | 49 | #else |
49 | #define swiotlb 0 | 50 | #define swiotlb 0 |
51 | static inline void pci_swiotlb_init(void) | ||
52 | { | ||
53 | } | ||
50 | #endif | 54 | #endif |
51 | 55 | ||
52 | extern void pci_swiotlb_init(void); | ||
53 | |||
54 | static inline void dma_mark_clean(void *addr, size_t size) {} | 56 | static inline void dma_mark_clean(void *addr, size_t size) {} |
55 | 57 | ||
56 | #endif /* _ASM_SWIOTLB_H */ | 58 | #endif /* _ASM_SWIOTLB_H */ |