diff options
author | FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> | 2009-10-27 03:34:44 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-11-08 07:12:26 -0500 |
commit | 338bac527ed0e35b4cb50390972f15d3cbce92ca (patch) | |
tree | c959878378523ba7f3bb0e30e98336549cadbdc0 /arch/x86/kernel/amd_iommu_init.c | |
parent | 7c9abfb884b8737f0afdc8a88bcea77526f0da87 (diff) |
x86: Use x86_platform for iommu_shutdown
This patch cleans up pci_iommu_shutdown() a bit to use
x86_platform (similar to how IA64 initializes an IOMMU driver).
This adds iommu_shutdown() to x86_platform to avoid calling
every IOMMUs' shutdown functions in pci_iommu_shutdown() in
order. The IOMMU shutdown functions are platform specific (we
don't have multiple different IOMMU hardware) so the current way
is pointless.
An IOMMU driver sets x86_platform.iommu_shutdown to the shutdown
function if necessary.
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Cc: joerg.roedel@amd.com
LKML-Reference: <20091027163358F.fujita.tomonori@lab.ntt.co.jp>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/amd_iommu_init.c')
-rw-r--r-- | arch/x86/kernel/amd_iommu_init.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/arch/x86/kernel/amd_iommu_init.c b/arch/x86/kernel/amd_iommu_init.c index c20001e4f556..6acd43e9afd7 100644 --- a/arch/x86/kernel/amd_iommu_init.c +++ b/arch/x86/kernel/amd_iommu_init.c | |||
@@ -1297,6 +1297,7 @@ int __init amd_iommu_init(void) | |||
1297 | else | 1297 | else |
1298 | printk(KERN_INFO "AMD-Vi: Lazy IO/TLB flushing enabled\n"); | 1298 | printk(KERN_INFO "AMD-Vi: Lazy IO/TLB flushing enabled\n"); |
1299 | 1299 | ||
1300 | x86_platform.iommu_shutdown = disable_iommus; | ||
1300 | out: | 1301 | out: |
1301 | return ret; | 1302 | return ret; |
1302 | 1303 | ||
@@ -1323,11 +1324,6 @@ free: | |||
1323 | goto out; | 1324 | goto out; |
1324 | } | 1325 | } |
1325 | 1326 | ||
1326 | void amd_iommu_shutdown(void) | ||
1327 | { | ||
1328 | disable_iommus(); | ||
1329 | } | ||
1330 | |||
1331 | /**************************************************************************** | 1327 | /**************************************************************************** |
1332 | * | 1328 | * |
1333 | * Early detect code. This code runs at IOMMU detection time in the DMA | 1329 | * Early detect code. This code runs at IOMMU detection time in the DMA |