aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86_64/kernel/pci-gart.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/x86_64/kernel/pci-gart.c')
-rw-r--r--arch/x86_64/kernel/pci-gart.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/arch/x86_64/kernel/pci-gart.c b/arch/x86_64/kernel/pci-gart.c
index 4f67957d2b42..9a93954bed37 100644
--- a/arch/x86_64/kernel/pci-gart.c
+++ b/arch/x86_64/kernel/pci-gart.c
@@ -571,7 +571,7 @@ static struct dma_mapping_ops gart_dma_ops = {
571 .unmap_sg = gart_unmap_sg, 571 .unmap_sg = gart_unmap_sg,
572}; 572};
573 573
574static int __init pci_iommu_init(void) 574void __init gart_iommu_init(void)
575{ 575{
576 struct agp_kern_info info; 576 struct agp_kern_info info;
577 unsigned long aper_size; 577 unsigned long aper_size;
@@ -581,7 +581,7 @@ static int __init pci_iommu_init(void)
581 581
582 if (cache_k8_northbridges() < 0 || num_k8_northbridges == 0) { 582 if (cache_k8_northbridges() < 0 || num_k8_northbridges == 0) {
583 printk(KERN_INFO "PCI-GART: No AMD northbridge found.\n"); 583 printk(KERN_INFO "PCI-GART: No AMD northbridge found.\n");
584 return -ENODEV; 584 return;
585 } 585 }
586 586
587#ifndef CONFIG_AGP_AMD64 587#ifndef CONFIG_AGP_AMD64
@@ -595,11 +595,11 @@ static int __init pci_iommu_init(void)
595#endif 595#endif
596 596
597 if (swiotlb) 597 if (swiotlb)
598 return -ENODEV; 598 return;
599 599
600 /* Did we detect a different HW IOMMU? */ 600 /* Did we detect a different HW IOMMU? */
601 if (iommu_detected && !iommu_aperture) 601 if (iommu_detected && !iommu_aperture)
602 return -1; 602 return;
603 603
604 if (no_iommu || 604 if (no_iommu ||
605 (!force_iommu && end_pfn <= MAX_DMA32_PFN) || 605 (!force_iommu && end_pfn <= MAX_DMA32_PFN) ||
@@ -611,7 +611,7 @@ static int __init pci_iommu_init(void)
611 "but IOMMU not available.\n" 611 "but IOMMU not available.\n"
612 KERN_ERR "WARNING 32bit PCI may malfunction.\n"); 612 KERN_ERR "WARNING 32bit PCI may malfunction.\n");
613 } 613 }
614 return -ENODEV; 614 return;
615 } 615 }
616 616
617 printk(KERN_INFO "PCI-DMA: using GART IOMMU.\n"); 617 printk(KERN_INFO "PCI-DMA: using GART IOMMU.\n");
@@ -678,11 +678,10 @@ static int __init pci_iommu_init(void)
678 678
679 flush_gart(); 679 flush_gart();
680 dma_ops = &gart_dma_ops; 680 dma_ops = &gart_dma_ops;
681 return 0;
682} 681}
683 682
684/* Must execute after PCI subsystem */ 683/* Must execute after PCI subsystem */
685fs_initcall(pci_iommu_init); 684fs_initcall(gart_iommu_init);
686 685
687void gart_parse_options(char *p) 686void gart_parse_options(char *p)
688{ 687{