xref: /linux/arch/x86/kvm/Kconfig (revision d6fd48ef)
1# SPDX-License-Identifier: GPL-2.0
2#
3# KVM configuration
4#
5
6source "virt/kvm/Kconfig"
7
8menuconfig VIRTUALIZATION
9	bool "Virtualization"
10	depends on HAVE_KVM || X86
11	default y
12	help
13	  Say Y here to get to see options for using your Linux host to run other
14	  operating systems inside virtual machines (guests).
15	  This option alone does not add any kernel code.
16
17	  If you say N, all options in this submenu will be skipped and disabled.
18
19if VIRTUALIZATION
20
21config KVM
22	tristate "Kernel-based Virtual Machine (KVM) support"
23	depends on HAVE_KVM
24	depends on HIGH_RES_TIMERS
25	depends on X86_LOCAL_APIC
26	select PREEMPT_NOTIFIERS
27	select MMU_NOTIFIER
28	select HAVE_KVM_IRQCHIP
29	select HAVE_KVM_PFNCACHE
30	select HAVE_KVM_IRQFD
31	select HAVE_KVM_DIRTY_RING_TSO
32	select HAVE_KVM_DIRTY_RING_ACQ_REL
33	select IRQ_BYPASS_MANAGER
34	select HAVE_KVM_IRQ_BYPASS
35	select HAVE_KVM_IRQ_ROUTING
36	select HAVE_KVM_EVENTFD
37	select KVM_ASYNC_PF
38	select USER_RETURN_NOTIFIER
39	select KVM_MMIO
40	select SCHED_INFO
41	select PERF_EVENTS
42	select GUEST_PERF_EVENTS
43	select HAVE_KVM_MSI
44	select HAVE_KVM_CPU_RELAX_INTERCEPT
45	select HAVE_KVM_NO_POLL
46	select KVM_XFER_TO_GUEST_WORK
47	select KVM_GENERIC_DIRTYLOG_READ_PROTECT
48	select KVM_VFIO
49	select SRCU
50	select INTERVAL_TREE
51	select HAVE_KVM_PM_NOTIFIER if PM
52	select KVM_GENERIC_HARDWARE_ENABLING
53	help
54	  Support hosting fully virtualized guest machines using hardware
55	  virtualization extensions.  You will need a fairly recent
56	  processor equipped with virtualization extensions. You will also
57	  need to select one or more of the processor modules below.
58
59	  This module provides access to the hardware capabilities through
60	  a character device node named /dev/kvm.
61
62	  To compile this as a module, choose M here: the module
63	  will be called kvm.
64
65	  If unsure, say N.
66
67config KVM_WERROR
68	bool "Compile KVM with -Werror"
69	# KASAN may cause the build to fail due to larger frames
70	default y if X86_64 && !KASAN
71	# We use the dependency on !COMPILE_TEST to not be enabled
72	# blindly in allmodconfig or allyesconfig configurations
73	depends on KVM
74	depends on (X86_64 && !KASAN) || !COMPILE_TEST
75	depends on EXPERT
76	help
77	  Add -Werror to the build flags for KVM.
78
79	  If in doubt, say "N".
80
81config KVM_INTEL
82	tristate "KVM for Intel (and compatible) processors support"
83	depends on KVM && IA32_FEAT_CTL
84	help
85	  Provides support for KVM on processors equipped with Intel's VT
86	  extensions, a.k.a. Virtual Machine Extensions (VMX).
87
88	  To compile this as a module, choose M here: the module
89	  will be called kvm-intel.
90
91config X86_SGX_KVM
92	bool "Software Guard eXtensions (SGX) Virtualization"
93	depends on X86_SGX && KVM_INTEL
94	help
95
96	  Enables KVM guests to create SGX enclaves.
97
98	  This includes support to expose "raw" unreclaimable enclave memory to
99	  guests via a device node, e.g. /dev/sgx_vepc.
100
101	  If unsure, say N.
102
103config KVM_AMD
104	tristate "KVM for AMD processors support"
105	depends on KVM
106	help
107	  Provides support for KVM on AMD processors equipped with the AMD-V
108	  (SVM) extensions.
109
110	  To compile this as a module, choose M here: the module
111	  will be called kvm-amd.
112
113config KVM_AMD_SEV
114	def_bool y
115	bool "AMD Secure Encrypted Virtualization (SEV) support"
116	depends on KVM_AMD && X86_64
117	depends on CRYPTO_DEV_SP_PSP && !(KVM_AMD=y && CRYPTO_DEV_CCP_DD=m)
118	help
119	  Provides support for launching Encrypted VMs (SEV) and Encrypted VMs
120	  with Encrypted State (SEV-ES) on AMD processors.
121
122config KVM_SMM
123	bool "System Management Mode emulation"
124	default y
125	depends on KVM
126	help
127	  Provides support for KVM to emulate System Management Mode (SMM)
128	  in virtual machines.  This can be used by the virtual machine
129	  firmware to implement UEFI secure boot.
130
131	  If unsure, say Y.
132
133config KVM_XEN
134	bool "Support for Xen hypercall interface"
135	depends on KVM
136	help
137	  Provides KVM support for the hosting Xen HVM guests and
138	  passing Xen hypercalls to userspace.
139
140	  If in doubt, say "N".
141
142config KVM_EXTERNAL_WRITE_TRACKING
143	bool
144
145endif # VIRTUALIZATION
146