[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH v2 1/8] x86/iommu: introduce AMD-Vi and Intel VT-d Kconfig options



Introduce two new Kconfig options, AMD_IOMMU and INTEL_IOMMU, to allow code
specific to each IOMMU technology to be separated and, when not required,
stripped. AMD_IOMMU will be used to enable IOMMU support for platforms that
implement the AMD I/O Virtualization Technology. INTEL_IOMMU will be used to
enable IOMMU support for platforms that implement the Intel Virtualization
Technology for Directed I/O.

Since, at this point, disabling any of them would cause Xen to not compile,
the options are not visible to the user and are enabled by default if X86.

Signed-off-by: Xenia Ragiadakou <burzalodowa@xxxxxxxxx>
---

Changes in v2:
  - just introduce the new options but not make them selectable by the user
  - adjust commit message
  - replace CONFIG_INTEL_VTD with CONFIG_INTEL_IOMMU

 xen/drivers/passthrough/Kconfig  | 6 ++++++
 xen/drivers/passthrough/Makefile | 4 ++--
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/xen/drivers/passthrough/Kconfig b/xen/drivers/passthrough/Kconfig
index 479d7de57a..5c65567744 100644
--- a/xen/drivers/passthrough/Kconfig
+++ b/xen/drivers/passthrough/Kconfig
@@ -37,6 +37,12 @@ config IPMMU_VMSA
 
 endif
 
+config AMD_IOMMU
+       def_bool y if X86
+
+config INTEL_IOMMU
+       def_bool y if X86
+
 config IOMMU_FORCE_PT_SHARE
        bool
 
diff --git a/xen/drivers/passthrough/Makefile b/xen/drivers/passthrough/Makefile
index a5efa22714..a1621540b7 100644
--- a/xen/drivers/passthrough/Makefile
+++ b/xen/drivers/passthrough/Makefile
@@ -1,5 +1,5 @@
-obj-$(CONFIG_X86) += vtd/
-obj-$(CONFIG_X86) += amd/
+obj-$(CONFIG_INTEL_IOMMU) += vtd/
+obj-$(CONFIG_AMD_IOMMU) += amd/
 obj-$(CONFIG_X86) += x86/
 obj-$(CONFIG_ARM) += arm/
 
-- 
2.37.2




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.