diff options
Diffstat (limited to 'arch/x86/include')
| -rw-r--r-- | arch/x86/include/asm/dma-mapping.h | 2 | ||||
| -rw-r--r-- | arch/x86/include/asm/gart.h | 33 | ||||
| -rw-r--r-- | arch/x86/include/asm/io.h | 2 | ||||
| -rw-r--r-- | arch/x86/include/asm/io_64.h | 2 | ||||
| -rw-r--r-- | arch/x86/include/asm/iommu.h | 33 |
5 files changed, 33 insertions, 39 deletions
diff --git a/arch/x86/include/asm/dma-mapping.h b/arch/x86/include/asm/dma-mapping.h index 097794ff6b7..dc22c073328 100644 --- a/arch/x86/include/asm/dma-mapping.h +++ b/arch/x86/include/asm/dma-mapping.h | |||
| @@ -71,12 +71,10 @@ static inline struct dma_mapping_ops *get_dma_ops(struct device *dev) | |||
| 71 | /* Make sure we keep the same behaviour */ | 71 | /* Make sure we keep the same behaviour */ |
| 72 | static inline int dma_mapping_error(struct device *dev, dma_addr_t dma_addr) | 72 | static inline int dma_mapping_error(struct device *dev, dma_addr_t dma_addr) |
| 73 | { | 73 | { |
| 74 | #ifdef CONFIG_X86_64 | ||
| 75 | struct dma_mapping_ops *ops = get_dma_ops(dev); | 74 | struct dma_mapping_ops *ops = get_dma_ops(dev); |
| 76 | if (ops->mapping_error) | 75 | if (ops->mapping_error) |
| 77 | return ops->mapping_error(dev, dma_addr); | 76 | return ops->mapping_error(dev, dma_addr); |
| 78 | 77 | ||
| 79 | #endif | ||
| 80 | return (dma_addr == bad_dma_address); | 78 | return (dma_addr == bad_dma_address); |
| 81 | } | 79 | } |
| 82 | 80 | ||
diff --git a/arch/x86/include/asm/gart.h b/arch/x86/include/asm/gart.h index 74252264433..6cfdafa409d 100644 --- a/arch/x86/include/asm/gart.h +++ b/arch/x86/include/asm/gart.h | |||
| @@ -29,6 +29,39 @@ extern int fix_aperture; | |||
| 29 | #define AMD64_GARTCACHECTL 0x9c | 29 | #define AMD64_GARTCACHECTL 0x9c |
| 30 | #define AMD64_GARTEN (1<<0) | 30 | #define AMD64_GARTEN (1<<0) |
| 31 | 31 | ||
| 32 | #ifdef CONFIG_GART_IOMMU | ||
| 33 | extern int gart_iommu_aperture; | ||
| 34 | extern int gart_iommu_aperture_allowed; | ||
| 35 | extern int gart_iommu_aperture_disabled; | ||
| 36 | |||
| 37 | extern void early_gart_iommu_check(void); | ||
| 38 | extern void gart_iommu_init(void); | ||
| 39 | extern void gart_iommu_shutdown(void); | ||
| 40 | extern void __init gart_parse_options(char *); | ||
| 41 | extern void gart_iommu_hole_init(void); | ||
| 42 | |||
| 43 | #else | ||
| 44 | #define gart_iommu_aperture 0 | ||
| 45 | #define gart_iommu_aperture_allowed 0 | ||
| 46 | #define gart_iommu_aperture_disabled 1 | ||
| 47 | |||
| 48 | static inline void early_gart_iommu_check(void) | ||
| 49 | { | ||
| 50 | } | ||
| 51 | static inline void gart_iommu_init(void) | ||
| 52 | { | ||
| 53 | } | ||
| 54 | static inline void gart_iommu_shutdown(void) | ||
| 55 | { | ||
| 56 | } | ||
| 57 | static inline void gart_parse_options(char *options) | ||
| 58 | { | ||
| 59 | } | ||
| 60 | static inline void gart_iommu_hole_init(void) | ||
| 61 | { | ||
| 62 | } | ||
| 63 | #endif | ||
| 64 | |||
| 32 | extern int agp_amd64_init(void); | 65 | extern int agp_amd64_init(void); |
| 33 | 66 | ||
| 34 | static inline void enable_gart_translation(struct pci_dev *dev, u64 addr) | 67 | static inline void enable_gart_translation(struct pci_dev *dev, u64 addr) |
diff --git a/arch/x86/include/asm/io.h b/arch/x86/include/asm/io.h index 33513b9a67f..05cfed4485f 100644 --- a/arch/x86/include/asm/io.h +++ b/arch/x86/include/asm/io.h | |||
| @@ -80,8 +80,6 @@ static inline void writeq(__u64 val, volatile void __iomem *addr) | |||
| 80 | #define readq readq | 80 | #define readq readq |
| 81 | #define writeq writeq | 81 | #define writeq writeq |
| 82 | 82 | ||
| 83 | extern int iommu_bio_merge; | ||
| 84 | |||
| 85 | #ifdef CONFIG_X86_32 | 83 | #ifdef CONFIG_X86_32 |
| 86 | # include "io_32.h" | 84 | # include "io_32.h" |
| 87 | #else | 85 | #else |
diff --git a/arch/x86/include/asm/io_64.h b/arch/x86/include/asm/io_64.h index fea325a1122..563c16270ba 100644 --- a/arch/x86/include/asm/io_64.h +++ b/arch/x86/include/asm/io_64.h | |||
| @@ -232,8 +232,6 @@ void memset_io(volatile void __iomem *a, int b, size_t c); | |||
| 232 | 232 | ||
| 233 | #define flush_write_buffers() | 233 | #define flush_write_buffers() |
| 234 | 234 | ||
| 235 | #define BIO_VMERGE_BOUNDARY iommu_bio_merge | ||
| 236 | |||
| 237 | /* | 235 | /* |
| 238 | * Convert a virtual cached pointer to an uncached pointer | 236 | * Convert a virtual cached pointer to an uncached pointer |
| 239 | */ | 237 | */ |
diff --git a/arch/x86/include/asm/iommu.h b/arch/x86/include/asm/iommu.h index 0b500c5b644..295b13193f4 100644 --- a/arch/x86/include/asm/iommu.h +++ b/arch/x86/include/asm/iommu.h | |||
| @@ -12,37 +12,4 @@ extern unsigned long iommu_nr_pages(unsigned long addr, unsigned long len); | |||
| 12 | /* 10 seconds */ | 12 | /* 10 seconds */ |
| 13 | #define DMAR_OPERATION_TIMEOUT ((cycles_t) tsc_khz*10*1000) | 13 | #define DMAR_OPERATION_TIMEOUT ((cycles_t) tsc_khz*10*1000) |
| 14 | 14 | ||
| 15 | #ifdef CONFIG_GART_IOMMU | ||
| 16 | extern int gart_iommu_aperture; | ||
| 17 | extern int gart_iommu_aperture_allowed; | ||
| 18 | extern int gart_iommu_aperture_disabled; | ||
| 19 | |||
| 20 | extern void early_gart_iommu_check(void); | ||
| 21 | extern void gart_iommu_init(void); | ||
| 22 | extern void gart_iommu_shutdown(void); | ||
| 23 | extern void __init gart_parse_options(char *); | ||
| 24 | extern void gart_iommu_hole_init(void); | ||
| 25 | |||
| 26 | #else | ||
| 27 | #define gart_iommu_aperture 0 | ||
| 28 | #define gart_iommu_aperture_allowed 0 | ||
| 29 | #define gart_iommu_aperture_disabled 1 | ||
| 30 | |||
| 31 | static inline void early_gart_iommu_check(void) | ||
| 32 | { | ||
| 33 | } | ||
| 34 | static inline void gart_iommu_init(void) | ||
| 35 | { | ||
| 36 | } | ||
| 37 | static inline void gart_iommu_shutdown(void) | ||
| 38 | { | ||
| 39 | } | ||
| 40 | static inline void gart_parse_options(char *options) | ||
| 41 | { | ||
| 42 | } | ||
| 43 | static inline void gart_iommu_hole_init(void) | ||
| 44 | { | ||
| 45 | } | ||
| 46 | #endif | ||
| 47 | |||
| 48 | #endif /* _ASM_X86_IOMMU_H */ | 15 | #endif /* _ASM_X86_IOMMU_H */ |
