Skip to content

Commit 726fd8f

Browse files
kleikampvijay-suman
authored andcommitted
x86: Ignore iommu=off for AMD cpus
The kdump config scripts add the iommu=off kernel parameter which is problematic on AMD hardware. Just ignore it. Add an iommu=forceoff option in case anybody really wants to disable iommu on AMD. Orabug: 34779071 Signed-off-by: Dave Kleikamp <[email protected]> Reviewed-by: Darren Kenny <[email protected]>
1 parent 297a13c commit 726fd8f

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

arch/x86/kernel/pci-dma.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,13 @@ static __init int iommu_setup(char *p)
120120
return -EINVAL;
121121

122122
while (*p) {
123-
if (!strncmp(p, "off", 3))
123+
if (!strncmp(p, "off", 3)) {
124+
if (boot_cpu_data.x86_vendor == X86_VENDOR_AMD)
125+
pr_warn("iommu=off ignored on AMD. Use iommu=forceoff if you really mean it\n");
126+
else
127+
no_iommu = 1;
128+
}
129+
if (!strncmp(p, "forceoff", 8))
124130
no_iommu = 1;
125131
/* gart_parse_options has more force support */
126132
if (!strncmp(p, "force", 5))

0 commit comments

Comments
 (0)