Commit 0cd5c3c80a0ebd68c08312fa7d8c13149cc61c4c
Committed by
Ingo Molnar
1 parent
b534816b55
Exists in
master
and in
4 other branches
x86: disable intel_iommu support by default
Due to recurring issues with DMAR support on certain platforms. There's a number of filesystem corruption incidents reported: https://bugzilla.redhat.com/show_bug.cgi?id=479996 http://bugzilla.kernel.org/show_bug.cgi?id=12578 Provide a Kconfig option to change whether it is enabled by default. If disabled, it can still be reenabled by passing intel_iommu=on to the kernel. Keep the .config option off by default. Signed-off-by: Kyle McMartin <kyle@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Acked-By: David Woodhouse <David.Woodhouse@intel.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Showing 3 changed files with 24 additions and 3 deletions Side-by-side Diff
Documentation/kernel-parameters.txt
arch/x86/Kconfig
... | ... | @@ -1802,6 +1802,17 @@ |
1802 | 1802 | and include PCI device scope covered by these DMA |
1803 | 1803 | remapping devices. |
1804 | 1804 | |
1805 | +config DMAR_DEFAULT_ON | |
1806 | + def_bool n | |
1807 | + prompt "Enable DMA Remapping Devices by default" | |
1808 | + depends on DMAR | |
1809 | + help | |
1810 | + Selecting this option will enable a DMAR device at boot time if | |
1811 | + one is found. If this option is not selected, DMAR support can | |
1812 | + be enabled by passing intel_iommu=on to the kernel. It is | |
1813 | + recommended you say N here while the DMAR code remains | |
1814 | + experimental. | |
1815 | + | |
1805 | 1816 | config DMAR_GFX_WA |
1806 | 1817 | def_bool y |
1807 | 1818 | prompt "Support for Graphics workaround" |
drivers/pci/intel-iommu.c
... | ... | @@ -268,7 +268,12 @@ |
268 | 268 | |
269 | 269 | static void domain_remove_dev_info(struct dmar_domain *domain); |
270 | 270 | |
271 | -int dmar_disabled; | |
271 | +#ifdef CONFIG_DMAR_DEFAULT_ON | |
272 | +int dmar_disabled = 0; | |
273 | +#else | |
274 | +int dmar_disabled = 1; | |
275 | +#endif /*CONFIG_DMAR_DEFAULT_ON*/ | |
276 | + | |
272 | 277 | static int __initdata dmar_map_gfx = 1; |
273 | 278 | static int dmar_forcedac; |
274 | 279 | static int intel_iommu_strict; |
275 | 280 | |
... | ... | @@ -284,9 +289,12 @@ |
284 | 289 | if (!str) |
285 | 290 | return -EINVAL; |
286 | 291 | while (*str) { |
287 | - if (!strncmp(str, "off", 3)) { | |
292 | + if (!strncmp(str, "on", 2)) { | |
293 | + dmar_disabled = 0; | |
294 | + printk(KERN_INFO "Intel-IOMMU: enabled\n"); | |
295 | + } else if (!strncmp(str, "off", 3)) { | |
288 | 296 | dmar_disabled = 1; |
289 | - printk(KERN_INFO"Intel-IOMMU: disabled\n"); | |
297 | + printk(KERN_INFO "Intel-IOMMU: disabled\n"); | |
290 | 298 | } else if (!strncmp(str, "igfx_off", 8)) { |
291 | 299 | dmar_map_gfx = 0; |
292 | 300 | printk(KERN_INFO |