aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel
diff options
context:
space:
mode:
authorJoerg Roedel <joerg.roedel@amd.com>2007-10-24 06:49:50 -0400
committerThomas Gleixner <tglx@linutronix.de>2007-10-29 19:22:22 -0400
commit0440d4c00dadf8b97657c0864e4d54a088430de8 (patch)
tree4750cbab8af0b2b948519553ca19a724fdce8d24 /arch/x86/kernel
parent79da0874410c0af8958f0ee3a50aa5b67eecc640 (diff)
x86 gart: rename symbols only used for the GART implementation
This patch renames the 4 symbols iommu_hole_init(), iommu_aperture, iommu_aperture_allowed, iommu_aperture_disabled. All these symbols are only used for the GART implementation of IOMMUs. It adds and additional gart_ prefix to them. Signed-off-by: Joerg Roedel <joerg.roedel@amd.com> Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'arch/x86/kernel')
-rw-r--r--arch/x86/kernel/aperture_64.c13
-rw-r--r--arch/x86/kernel/early-quirks.c4
-rw-r--r--arch/x86/kernel/pci-dma_64.c2
-rw-r--r--arch/x86/kernel/pci-gart_64.c8
4 files changed, 14 insertions, 13 deletions
diff --git a/arch/x86/kernel/aperture_64.c b/arch/x86/kernel/aperture_64.c
index 70c854fdfb21..5b6992799c9d 100644
--- a/arch/x86/kernel/aperture_64.c
+++ b/arch/x86/kernel/aperture_64.c
@@ -25,9 +25,9 @@
25#include <asm/dma.h> 25#include <asm/dma.h>
26#include <asm/k8.h> 26#include <asm/k8.h>
27 27
28int iommu_aperture; 28int gart_iommu_aperture;
29int iommu_aperture_disabled __initdata = 0; 29int gart_iommu_aperture_disabled __initdata = 0;
30int iommu_aperture_allowed __initdata = 0; 30int gart_iommu_aperture_allowed __initdata = 0;
31 31
32int fallback_aper_order __initdata = 1; /* 64MB */ 32int fallback_aper_order __initdata = 1; /* 64MB */
33int fallback_aper_force __initdata = 0; 33int fallback_aper_force __initdata = 0;
@@ -204,14 +204,15 @@ static __u32 __init search_agp_bridge(u32 *order, int *valid_agp)
204 return 0; 204 return 0;
205} 205}
206 206
207void __init iommu_hole_init(void) 207void __init gart_iommu_hole_init(void)
208{ 208{
209 int fix, num; 209 int fix, num;
210 u32 aper_size, aper_alloc = 0, aper_order = 0, last_aper_order = 0; 210 u32 aper_size, aper_alloc = 0, aper_order = 0, last_aper_order = 0;
211 u64 aper_base, last_aper_base = 0; 211 u64 aper_base, last_aper_base = 0;
212 int valid_agp = 0; 212 int valid_agp = 0;
213 213
214 if (iommu_aperture_disabled || !fix_aperture || !early_pci_allowed()) 214 if (gart_iommu_aperture_disabled || !fix_aperture ||
215 !early_pci_allowed())
215 return; 216 return;
216 217
217 printk(KERN_INFO "Checking aperture...\n"); 218 printk(KERN_INFO "Checking aperture...\n");
@@ -222,7 +223,7 @@ void __init iommu_hole_init(void)
222 continue; 223 continue;
223 224
224 iommu_detected = 1; 225 iommu_detected = 1;
225 iommu_aperture = 1; 226 gart_iommu_aperture = 1;
226 227
227 aper_order = (read_pci_config(0, num, 3, 0x90) >> 1) & 7; 228 aper_order = (read_pci_config(0, num, 3, 0x90) >> 1) & 7;
228 aper_size = (32 * 1024 * 1024) << aper_order; 229 aper_size = (32 * 1024 * 1024) << aper_order;
diff --git a/arch/x86/kernel/early-quirks.c b/arch/x86/kernel/early-quirks.c
index b8265c1ea0d3..88bb83ec895f 100644
--- a/arch/x86/kernel/early-quirks.c
+++ b/arch/x86/kernel/early-quirks.c
@@ -25,11 +25,11 @@ static void __init via_bugs(void)
25{ 25{
26#ifdef CONFIG_GART_IOMMU 26#ifdef CONFIG_GART_IOMMU
27 if ((end_pfn > MAX_DMA32_PFN || force_iommu) && 27 if ((end_pfn > MAX_DMA32_PFN || force_iommu) &&
28 !iommu_aperture_allowed) { 28 !gart_iommu_aperture_allowed) {
29 printk(KERN_INFO 29 printk(KERN_INFO
30 "Looks like a VIA chipset. Disabling IOMMU." 30 "Looks like a VIA chipset. Disabling IOMMU."
31 " Override with iommu=allowed\n"); 31 " Override with iommu=allowed\n");
32 iommu_aperture_disabled = 1; 32 gart_iommu_aperture_disabled = 1;
33 } 33 }
34#endif 34#endif
35} 35}
diff --git a/arch/x86/kernel/pci-dma_64.c b/arch/x86/kernel/pci-dma_64.c
index 66b3dc5b3f45..aa805b11b24f 100644
--- a/arch/x86/kernel/pci-dma_64.c
+++ b/arch/x86/kernel/pci-dma_64.c
@@ -299,7 +299,7 @@ void __init pci_iommu_alloc(void)
299 * fall-back/fail-over reasons 299 * fall-back/fail-over reasons
300 */ 300 */
301#ifdef CONFIG_GART_IOMMU 301#ifdef CONFIG_GART_IOMMU
302 iommu_hole_init(); 302 gart_iommu_hole_init();
303#endif 303#endif
304 304
305#ifdef CONFIG_CALGARY_IOMMU 305#ifdef CONFIG_CALGARY_IOMMU
diff --git a/arch/x86/kernel/pci-gart_64.c b/arch/x86/kernel/pci-gart_64.c
index 3be0b83dc4cb..06bcba536045 100644
--- a/arch/x86/kernel/pci-gart_64.c
+++ b/arch/x86/kernel/pci-gart_64.c
@@ -627,12 +627,12 @@ void __init gart_iommu_init(void)
627 return; 627 return;
628 628
629 /* Did we detect a different HW IOMMU? */ 629 /* Did we detect a different HW IOMMU? */
630 if (iommu_detected && !iommu_aperture) 630 if (iommu_detected && !gart_iommu_aperture)
631 return; 631 return;
632 632
633 if (no_iommu || 633 if (no_iommu ||
634 (!force_iommu && end_pfn <= MAX_DMA32_PFN) || 634 (!force_iommu && end_pfn <= MAX_DMA32_PFN) ||
635 !iommu_aperture || 635 !gart_iommu_aperture ||
636 (no_agp && init_k8_gatt(&info) < 0)) { 636 (no_agp && init_k8_gatt(&info) < 0)) {
637 if (end_pfn > MAX_DMA32_PFN) { 637 if (end_pfn > MAX_DMA32_PFN) {
638 printk(KERN_ERR "WARNING more than 4GB of memory " 638 printk(KERN_ERR "WARNING more than 4GB of memory "
@@ -733,9 +733,9 @@ void __init gart_parse_options(char *p)
733 fix_aperture = 0; 733 fix_aperture = 0;
734 /* duplicated from pci-dma.c */ 734 /* duplicated from pci-dma.c */
735 if (!strncmp(p,"force",5)) 735 if (!strncmp(p,"force",5))
736 iommu_aperture_allowed = 1; 736 gart_iommu_aperture_allowed = 1;
737 if (!strncmp(p,"allowed",7)) 737 if (!strncmp(p,"allowed",7))
738 iommu_aperture_allowed = 1; 738 gart_iommu_aperture_allowed = 1;
739 if (!strncmp(p, "memaper", 7)) { 739 if (!strncmp(p, "memaper", 7)) {
740 fallback_aper_force = 1; 740 fallback_aper_force = 1;
741 p += 7; 741 p += 7;