Greg Kroah-Hartman | b244131 | 2017-11-01 15:07:57 +0100 | [diff] [blame] | 1 | # SPDX-License-Identifier: GPL-2.0 |
Sanjay Lal | 2235a54 | 2012-11-21 18:33:59 -0800 | [diff] [blame] | 2 | # |
| 3 | # KVM configuration |
| 4 | # |
| 5 | source "virt/kvm/Kconfig" |
| 6 | |
| 7 | menuconfig VIRTUALIZATION |
| 8 | bool "Virtualization" |
Masahiro Yamada | a7f7f62 | 2020-06-14 01:50:22 +0900 | [diff] [blame^] | 9 | help |
Sanjay Lal | 2235a54 | 2012-11-21 18:33:59 -0800 | [diff] [blame] | 10 | Say Y here to get to see options for using your Linux host to run |
| 11 | other operating systems inside virtual machines (guests). |
| 12 | This option alone does not add any kernel code. |
| 13 | |
| 14 | If you say N, all options in this submenu will be skipped and disabled. |
| 15 | |
| 16 | if VIRTUALIZATION |
| 17 | |
| 18 | config KVM |
| 19 | tristate "Kernel-based Virtual Machine (KVM) support" |
| 20 | depends on HAVE_KVM |
Paul Burton | c92e47e | 2018-11-07 23:14:02 +0000 | [diff] [blame] | 21 | depends on MIPS_FP_SUPPORT |
James Hogan | 90e9311 | 2016-06-23 17:34:39 +0100 | [diff] [blame] | 22 | select EXPORT_UASM |
Sanjay Lal | 2235a54 | 2012-11-21 18:33:59 -0800 | [diff] [blame] | 23 | select PREEMPT_NOTIFIERS |
James Hogan | e88643b | 2016-12-06 14:50:52 +0000 | [diff] [blame] | 24 | select KVM_GENERIC_DIRTYLOG_READ_PROTECT |
Paolo Bonzini | 5cb0944 | 2017-12-12 17:41:34 +0100 | [diff] [blame] | 25 | select HAVE_KVM_VCPU_ASYNC_IOCTL |
Sanjay Lal | 2235a54 | 2012-11-21 18:33:59 -0800 | [diff] [blame] | 26 | select KVM_MMIO |
James Hogan | 411740f | 2016-12-13 16:32:39 +0000 | [diff] [blame] | 27 | select MMU_NOTIFIER |
Pranith Kumar | 83fe27e | 2014-12-05 11:24:45 -0500 | [diff] [blame] | 28 | select SRCU |
Masahiro Yamada | a7f7f62 | 2020-06-14 01:50:22 +0900 | [diff] [blame^] | 29 | help |
Sanjay Lal | 2235a54 | 2012-11-21 18:33:59 -0800 | [diff] [blame] | 30 | Support for hosting Guest kernels. |
James Hogan | 56f7a44 | 2017-03-14 10:15:32 +0000 | [diff] [blame] | 31 | |
| 32 | choice |
| 33 | prompt "Virtualization mode" |
| 34 | depends on KVM |
| 35 | default KVM_MIPS_TE |
| 36 | |
| 37 | config KVM_MIPS_TE |
| 38 | bool "Trap & Emulate" |
Masahiro Yamada | a7f7f62 | 2020-06-14 01:50:22 +0900 | [diff] [blame^] | 39 | help |
James Hogan | 56f7a44 | 2017-03-14 10:15:32 +0000 | [diff] [blame] | 40 | Use trap and emulate to virtualize 32-bit guests in user mode. This |
| 41 | does not require any special hardware Virtualization support beyond |
| 42 | standard MIPS32/64 r2 or later, but it does require the guest kernel |
| 43 | to be configured with CONFIG_KVM_GUEST=y so that it resides in the |
| 44 | user address segment. |
| 45 | |
| 46 | config KVM_MIPS_VZ |
| 47 | bool "MIPS Virtualization (VZ) ASE" |
Masahiro Yamada | a7f7f62 | 2020-06-14 01:50:22 +0900 | [diff] [blame^] | 48 | help |
James Hogan | 56f7a44 | 2017-03-14 10:15:32 +0000 | [diff] [blame] | 49 | Use the MIPS Virtualization (VZ) ASE to virtualize guests. This |
| 50 | supports running unmodified guest kernels (with CONFIG_KVM_GUEST=n), |
| 51 | but requires hardware support. |
| 52 | |
| 53 | endchoice |
Sanjay Lal | 2235a54 | 2012-11-21 18:33:59 -0800 | [diff] [blame] | 54 | |
| 55 | config KVM_MIPS_DYN_TRANS |
| 56 | bool "KVM/MIPS: Dynamic binary translation to reduce traps" |
James Hogan | 56f7a44 | 2017-03-14 10:15:32 +0000 | [diff] [blame] | 57 | depends on KVM_MIPS_TE |
| 58 | default y |
Masahiro Yamada | a7f7f62 | 2020-06-14 01:50:22 +0900 | [diff] [blame^] | 59 | help |
Sanjay Lal | 2235a54 | 2012-11-21 18:33:59 -0800 | [diff] [blame] | 60 | When running in Trap & Emulate mode patch privileged |
| 61 | instructions to reduce the number of traps. |
| 62 | |
| 63 | If unsure, say Y. |
| 64 | |
| 65 | config KVM_MIPS_DEBUG_COP0_COUNTERS |
| 66 | bool "Maintain counters for COP0 accesses" |
| 67 | depends on KVM |
Masahiro Yamada | a7f7f62 | 2020-06-14 01:50:22 +0900 | [diff] [blame^] | 68 | help |
Sanjay Lal | 2235a54 | 2012-11-21 18:33:59 -0800 | [diff] [blame] | 69 | Maintain statistics for Guest COP0 accesses. |
| 70 | A histogram of COP0 accesses is printed when the VM is |
| 71 | shutdown. |
| 72 | |
| 73 | If unsure, say N. |
| 74 | |
Sanjay Lal | 2235a54 | 2012-11-21 18:33:59 -0800 | [diff] [blame] | 75 | endif # VIRTUALIZATION |