Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4751a951 authored by Joerg Roedel's avatar Joerg Roedel
Browse files

x86/amd-iommu: Initialize passthrough mode when requested



This patch enables the passthrough mode for AMD IOMMU by
running the initialization function when iommu=pt is passed
on the kernel command line.

Signed-off-by: default avatarJoerg Roedel <joerg.roedel@amd.com>
parent a1ca331c
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -1242,12 +1242,18 @@ int __init amd_iommu_init(void)
	if (ret)
		goto free;

	if (iommu_pass_through)
		ret = amd_iommu_init_passthrough();
	else
		ret = amd_iommu_init_dma_ops();
	if (ret)
		goto free;

	enable_iommus();

	if (iommu_pass_through)
		goto out;

	printk(KERN_INFO "AMD IOMMU: device isolation ");
	if (amd_iommu_isolate)
		printk("enabled\n");