1# SPDX-License-Identifier: GPL-2.0-only 2# Intel IOMMU support 3config DMAR_TABLE 4 bool 5 6config INTEL_IOMMU 7 bool "Support for Intel IOMMU using DMA Remapping Devices" 8 depends on PCI_MSI && ACPI && (X86 || IA64) 9 select DMA_OPS 10 select IOMMU_API 11 select IOMMU_IOVA 12 select NEED_DMA_MAP_STATE 13 select DMAR_TABLE 14 select SWIOTLB 15 select IOASID 16 help 17 DMA remapping (DMAR) devices support enables independent address 18 translations for Direct Memory Access (DMA) from devices. 19 These DMA remapping devices are reported via ACPI tables 20 and include PCI device scope covered by these DMA 21 remapping devices. 22 23config INTEL_IOMMU_DEBUGFS 24 bool "Export Intel IOMMU internals in Debugfs" 25 depends on INTEL_IOMMU && IOMMU_DEBUGFS 26 help 27 !!!WARNING!!! 28 29 DO NOT ENABLE THIS OPTION UNLESS YOU REALLY KNOW WHAT YOU ARE DOING!!! 30 31 Expose Intel IOMMU internals in Debugfs. 32 33 This option is -NOT- intended for production environments, and should 34 only be enabled for debugging Intel IOMMU. 35 36config INTEL_IOMMU_SVM 37 bool "Support for Shared Virtual Memory with Intel IOMMU" 38 depends on INTEL_IOMMU && X86_64 39 select PCI_PASID 40 select PCI_PRI 41 select MMU_NOTIFIER 42 select IOASID 43 help 44 Shared Virtual Memory (SVM) provides a facility for devices 45 to access DMA resources through process address space by 46 means of a Process Address Space ID (PASID). 47 48config INTEL_IOMMU_DEFAULT_ON 49 def_bool y 50 prompt "Enable Intel DMA Remapping Devices by default" 51 depends on INTEL_IOMMU 52 help 53 Selecting this option will enable a DMAR device at boot time if 54 one is found. If this option is not selected, DMAR support can 55 be enabled by passing intel_iommu=on to the kernel. 56 57config INTEL_IOMMU_BROKEN_GFX_WA 58 bool "Workaround broken graphics drivers (going away soon)" 59 depends on INTEL_IOMMU && BROKEN && X86 60 help 61 Current Graphics drivers tend to use physical address 62 for DMA and avoid using DMA APIs. Setting this config 63 option permits the IOMMU driver to set a unity map for 64 all the OS-visible memory. Hence the driver can continue 65 to use physical addresses for DMA, at least until this 66 option is removed in the 2.6.32 kernel. 67 68config INTEL_IOMMU_FLOPPY_WA 69 def_bool y 70 depends on INTEL_IOMMU && X86 71 help 72 Floppy disk drivers are known to bypass DMA API calls 73 thereby failing to work when IOMMU is enabled. This 74 workaround will setup a 1:1 mapping for the first 75 16MiB to make floppy (an ISA device) work. 76 77config INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON 78 bool "Enable Intel IOMMU scalable mode by default" 79 depends on INTEL_IOMMU 80 help 81 Selecting this option will enable by default the scalable mode if 82 hardware presents the capability. The scalable mode is defined in 83 VT-d 3.0. The scalable mode capability could be checked by reading 84 /sys/devices/virtual/iommu/dmar*/intel-iommu/ecap. If this option 85 is not selected, scalable mode support could also be enabled by 86 passing intel_iommu=sm_on to the kernel. If not sure, please use 87 the default value. 88