summaryrefslogtreecommitdiff
path: root/arch/x86/kernel/amd_iommu_init.c
diff options
context:
space:
mode:
authorJoerg Roedel <joerg.roedel@amd.com>2010-01-22 17:44:35 +0100
committerJoerg Roedel <joerg.roedel@amd.com>2010-01-22 17:44:35 +0100
commitf5325094379158e6b876ea0010c807bf7890ec8f (patch)
tree54a40356a9076bddaac4186c1b97e2dbb98a5863 /arch/x86/kernel/amd_iommu_init.c
parent2ca762790caf822f7b61430fbaffa3ae4219977f (diff)
downloadlwn-f5325094379158e6b876ea0010c807bf7890ec8f.tar.gz
lwn-f5325094379158e6b876ea0010c807bf7890ec8f.zip
x86/amd-iommu: Fix IOMMU-API initialization for iommu=pt
This patch moves the initialization of the iommu-api out of the dma-ops initialization code. This ensures that the iommu-api is initialized even with iommu=pt. Cc: stable@kernel.org Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
Diffstat (limited to 'arch/x86/kernel/amd_iommu_init.c')
-rw-r--r--arch/x86/kernel/amd_iommu_init.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/arch/x86/kernel/amd_iommu_init.c b/arch/x86/kernel/amd_iommu_init.c
index fb490ce7dd55..9dc91b431470 100644
--- a/arch/x86/kernel/amd_iommu_init.c
+++ b/arch/x86/kernel/amd_iommu_init.c
@@ -1292,9 +1292,12 @@ static int __init amd_iommu_init(void)
ret = amd_iommu_init_passthrough();
else
ret = amd_iommu_init_dma_ops();
+
if (ret)
goto free;
+ amd_iommu_init_api();
+
amd_iommu_init_notifier();
enable_iommus();