blob: 6fb11e10477ba2f8df7d500cbd4f69f035da24f3 [file] [log] [blame]
Ohad Ben-Cohenab493a02011-06-02 02:48:05 +03001# IOMMU_API always gets selected by whoever wants it.
2config IOMMU_API
3 bool
Ohad Ben-Cohenb10f1272011-06-02 03:20:08 +03004
Joerg Roedel68255b62011-06-14 15:51:54 +02005menuconfig IOMMU_SUPPORT
6 bool "IOMMU Hardware Support"
7 default y
8 ---help---
9 Say Y here if you want to compile device drivers for IO Memory
10 Management Units into the kernel. These devices usually allow to
11 remap DMA requests and/or remap interrupts from other devices on the
12 system.
13
14if IOMMU_SUPPORT
15
Ohad Ben-Cohenb10f1272011-06-02 03:20:08 +030016# MSM IOMMU support
17config MSM_IOMMU
18 bool "MSM IOMMU Support"
Mitchel Humpherysd1717802012-11-09 09:54:54 -080019 depends on ARCH_MSM8X60 || ARCH_MSM8960 || ARCH_APQ8064 || ARCH_MSM8974 || ARCH_MPQ8092 || ARCH_MSM8910 || ARCH_MSM8226
Ohad Ben-Cohenb10f1272011-06-02 03:20:08 +030020 select IOMMU_API
21 help
22 Support for the IOMMUs found on certain Qualcomm SOCs.
23 These IOMMUs allow virtualization of the address space used by most
24 cores within the multimedia subsystem.
25
26 If unsure, say N here.
27
Olav Haugan65209cd2012-11-07 15:02:56 -080028# MSM IOMMU CPU-GPU sync programming support
29config MSM_IOMMU_GPU_SYNC
30 bool "MSM IOMMU CPU-GPU Sync Support"
31 depends on (ARCH_MSM8X60 || ARCH_MSM8960 || ARCH_APQ8064 || ARCH_MSM8930) && MSM_IOMMU && MSM_REMOTE_SPINLOCK_SFPB
32 help
33 Say Y here if you want to synchronize access to IOMMU configuration
34 port between CPU and GPU. CPU will grab a remote spinlock before
35 accessing IOMMU configuration registers and GPU will do the same.
36
37 If unsure, say N here.
38
Ohad Ben-Cohenb10f1272011-06-02 03:20:08 +030039config IOMMU_PGTABLES_L2
Steve Mucklef132c6c2012-06-06 18:30:57 -070040 bool "Allow SMMU page tables in the L2 cache (Experimental)"
Ohad Ben-Cohenb10f1272011-06-02 03:20:08 +030041 depends on MSM_IOMMU && MMU && SMP && CPU_DCACHE_DISABLE=n
Steve Mucklef132c6c2012-06-06 18:30:57 -070042 default y
43 help
44 Improves TLB miss latency at the expense of potential L2 pollution.
45 However, with large multimedia buffers, the TLB should mostly contain
46 section mappings and TLB misses should be quite infrequent.
47 Most people can probably say Y here.
Ohad Ben-Cohen29b68412011-06-05 18:22:18 +030048
49# AMD IOMMU support
50config AMD_IOMMU
51 bool "AMD IOMMU support"
52 select SWIOTLB
53 select PCI_MSI
Joerg Roedel52815b72011-11-17 17:24:28 +010054 select PCI_ATS
55 select PCI_PRI
56 select PCI_PASID
Ohad Ben-Cohen29b68412011-06-05 18:22:18 +030057 select IOMMU_API
58 depends on X86_64 && PCI && ACPI
59 ---help---
60 With this option you can enable support for AMD IOMMU hardware in
61 your system. An IOMMU is a hardware component which provides
62 remapping of DMA memory accesses from devices. With an AMD IOMMU you
63 can isolate the the DMA memory of different devices and protect the
64 system from misbehaving device drivers or hardware.
65
66 You can find out if your system has an AMD IOMMU if you look into
67 your BIOS for an option to enable it or if you have an IVRS ACPI
68 table.
69
70config AMD_IOMMU_STATS
71 bool "Export AMD IOMMU statistics to debugfs"
72 depends on AMD_IOMMU
73 select DEBUG_FS
74 ---help---
75 This option enables code in the AMD IOMMU driver to collect various
76 statistics about whats happening in the driver and exports that
77 information to userspace via debugfs.
78 If unsure, say N.
Ohad Ben-Cohen166e9272011-06-10 21:42:27 +030079
Joerg Roedele3c495c2011-11-09 12:31:15 +010080config AMD_IOMMU_V2
81 tristate "AMD IOMMU Version 2 driver (EXPERIMENTAL)"
Joerg Roedel8736b2c2011-11-24 16:21:52 +010082 depends on AMD_IOMMU && PROFILING && EXPERIMENTAL
83 select MMU_NOTIFIER
Joerg Roedele3c495c2011-11-09 12:31:15 +010084 ---help---
85 This option enables support for the AMD IOMMUv2 features of the IOMMU
86 hardware. Select this option if you want to use devices that support
87 the the PCI PRI and PASID interface.
88
Ohad Ben-Cohen166e9272011-06-10 21:42:27 +030089# Intel IOMMU support
Suresh Siddhad3f13812011-08-23 17:05:25 -070090config DMAR_TABLE
91 bool
92
93config INTEL_IOMMU
94 bool "Support for Intel IOMMU using DMA Remapping Devices"
Ohad Ben-Cohen166e9272011-06-10 21:42:27 +030095 depends on PCI_MSI && ACPI && (X86 || IA64_GENERIC)
96 select IOMMU_API
Suresh Siddhad3f13812011-08-23 17:05:25 -070097 select DMAR_TABLE
Ohad Ben-Cohen166e9272011-06-10 21:42:27 +030098 help
99 DMA remapping (DMAR) devices support enables independent address
100 translations for Direct Memory Access (DMA) from devices.
101 These DMA remapping devices are reported via ACPI tables
102 and include PCI device scope covered by these DMA
103 remapping devices.
104
Suresh Siddhad3f13812011-08-23 17:05:25 -0700105config INTEL_IOMMU_DEFAULT_ON
Ohad Ben-Cohen166e9272011-06-10 21:42:27 +0300106 def_bool y
Suresh Siddhad3f13812011-08-23 17:05:25 -0700107 prompt "Enable Intel DMA Remapping Devices by default"
108 depends on INTEL_IOMMU
Ohad Ben-Cohen166e9272011-06-10 21:42:27 +0300109 help
110 Selecting this option will enable a DMAR device at boot time if
111 one is found. If this option is not selected, DMAR support can
112 be enabled by passing intel_iommu=on to the kernel.
113
Suresh Siddhad3f13812011-08-23 17:05:25 -0700114config INTEL_IOMMU_BROKEN_GFX_WA
Ohad Ben-Cohen166e9272011-06-10 21:42:27 +0300115 bool "Workaround broken graphics drivers (going away soon)"
Suresh Siddhad3f13812011-08-23 17:05:25 -0700116 depends on INTEL_IOMMU && BROKEN && X86
Ohad Ben-Cohen166e9272011-06-10 21:42:27 +0300117 ---help---
118 Current Graphics drivers tend to use physical address
119 for DMA and avoid using DMA APIs. Setting this config
120 option permits the IOMMU driver to set a unity map for
121 all the OS-visible memory. Hence the driver can continue
122 to use physical addresses for DMA, at least until this
123 option is removed in the 2.6.32 kernel.
124
Suresh Siddhad3f13812011-08-23 17:05:25 -0700125config INTEL_IOMMU_FLOPPY_WA
Ohad Ben-Cohen166e9272011-06-10 21:42:27 +0300126 def_bool y
Suresh Siddhad3f13812011-08-23 17:05:25 -0700127 depends on INTEL_IOMMU && X86
Ohad Ben-Cohen166e9272011-06-10 21:42:27 +0300128 ---help---
129 Floppy disk drivers are known to bypass DMA API calls
130 thereby failing to work when IOMMU is enabled. This
131 workaround will setup a 1:1 mapping for the first
132 16MiB to make floppy (an ISA device) work.
133
Suresh Siddhad3f13812011-08-23 17:05:25 -0700134config IRQ_REMAP
Ohad Ben-Cohen166e9272011-06-10 21:42:27 +0300135 bool "Support for Interrupt Remapping (EXPERIMENTAL)"
136 depends on X86_64 && X86_IO_APIC && PCI_MSI && ACPI && EXPERIMENTAL
Suresh Siddhad3f13812011-08-23 17:05:25 -0700137 select DMAR_TABLE
Ohad Ben-Cohen166e9272011-06-10 21:42:27 +0300138 ---help---
139 Supports Interrupt remapping for IO-APIC and MSI devices.
140 To use x2apic mode in the CPU's which support x2APIC enhancements or
141 to support platforms with CPU's having > 8 bit APIC ID, say Y.
Joerg Roedel68255b62011-06-14 15:51:54 +0200142
Ohad Ben-Cohenfcf3a6e2011-08-15 23:21:41 +0300143# OMAP IOMMU support
144config OMAP_IOMMU
145 bool "OMAP IOMMU Support"
Ohad Ben-Cohen024ae882011-08-29 07:57:44 +0300146 depends on ARCH_OMAP
Ohad Ben-Cohenfcf3a6e2011-08-15 23:21:41 +0300147 select IOMMU_API
148
149config OMAP_IOVMM
Joerg Roedel7b6d45f2011-09-14 16:03:45 +0200150 tristate "OMAP IO Virtual Memory Manager Support"
151 depends on OMAP_IOMMU
Ohad Ben-Cohenfcf3a6e2011-08-15 23:21:41 +0300152
153config OMAP_IOMMU_DEBUG
154 tristate "Export OMAP IOMMU/IOVMM internals in DebugFS"
155 depends on OMAP_IOVMM && DEBUG_FS
156 help
157 Select this to see extensive information about
158 the internal state of OMAP IOMMU/IOVMM in debugfs.
159
160 Say N unless you know you need this.
161
Hiroshi DOYUd53e54b2011-11-16 17:36:37 +0200162config TEGRA_IOMMU_GART
163 bool "Tegra GART IOMMU Support"
164 depends on ARCH_TEGRA_2x_SOC
165 select IOMMU_API
166 help
167 Enables support for remapping discontiguous physical memory
168 shared with the operating system into contiguous I/O virtual
169 space through the GART (Graphics Address Relocation Table)
170 hardware included on Tegra SoCs.
171
Hiroshi DOYU7a31f6f2011-11-17 07:31:31 +0200172config TEGRA_IOMMU_SMMU
173 bool "Tegra SMMU IOMMU Support"
174 depends on ARCH_TEGRA_3x_SOC
175 select IOMMU_API
176 help
177 Enables support for remapping discontiguous physical memory
178 shared with the operating system into contiguous I/O virtual
179 space through the SMMU (System Memory Management Unit)
180 hardware included on Tegra SoCs.
181
Joerg Roedel68255b62011-06-14 15:51:54 +0200182endif # IOMMU_SUPPORT