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