Commit 06df6daf authored by FUJITA Tomonori's avatar FUJITA Tomonori Committed by Ingo Molnar

x86/agp: Fix amd64-agp module initialization regression

This fixes the regression introduced by commit
42590a75 ("x86/agp: Fix
agp_amd64_init and agp_amd64_cleanup").

The commit 61684cea fixed the
above regression but it's not enough. When amd64-agp is built as
a module, AGP isn't initialized, iommu is initialized, all the
aperture is owned by the iommu.
Reported-by: default avatarMarin Mitov <>
Signed-off-by: default avatarFUJITA Tomonori <>
Tested-by: default avatarMarin Mitov <>
LKML-Reference: <>
Signed-off-by: default avatarIngo Molnar <>
parent ab09809f
......@@ -767,16 +767,19 @@ int __init agp_amd64_init(void)
static int __init agp_amd64_mod_init(void)
#ifndef MODULE
if (gart_iommu_aperture)
return agp_bridges_found ? 0 : -ENODEV;
return agp_amd64_init();
static void __exit agp_amd64_cleanup(void)
#ifndef MODULE
if (gart_iommu_aperture)
if (aperture_resource)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment