xref: /openbmc/qemu/docs/system/i386/kvm-pv.rst (revision ffe98631)
1Paravirtualized KVM features
2============================
3
4Description
5-----------
6
7In some cases when implementing hardware interfaces in software is slow, ``KVM``
8implements its own paravirtualized interfaces.
9
10Setup
11-----
12
13Paravirtualized ``KVM`` features are represented as CPU flags. The following
14features are enabled by default for any CPU model when ``KVM`` acceleration is
15enabled:
16
17- ``kvmclock``
18- ``kvm-nopiodelay``
19- ``kvm-asyncpf``
20- ``kvm-steal-time``
21- ``kvm-pv-eoi``
22- ``kvmclock-stable-bit``
23
24``kvm-msi-ext-dest-id`` feature is enabled by default in x2apic mode with split
25irqchip (e.g. "-machine ...,kernel-irqchip=split -cpu ...,x2apic").
26
27Note: when CPU model ``host`` is used, QEMU passes through all supported
28paravirtualized ``KVM`` features to the guest.
29
30Existing features
31-----------------
32
33``kvmclock``
34  Expose a ``KVM`` specific paravirtualized clocksource to the guest. Supported
35  since Linux v2.6.26.
36
37``kvm-nopiodelay``
38  The guest doesn't need to perform delays on PIO operations. Supported since
39  Linux v2.6.26.
40
41``kvm-mmu``
42  This feature is deprecated.
43
44``kvm-asyncpf``
45  Enable asynchronous page fault mechanism. Supported since Linux v2.6.38.
46  Note: since Linux v5.10 the feature is deprecated and not enabled by ``KVM``.
47  Use ``kvm-asyncpf-int`` instead.
48
49``kvm-steal-time``
50  Enable stolen (when guest vCPU is not running) time accounting. Supported
51  since Linux v3.1.
52
53``kvm-pv-eoi``
54  Enable paravirtualized end-of-interrupt signaling. Supported since Linux
55  v3.10.
56
57``kvm-pv-unhalt``
58  Enable paravirtualized spinlocks support. Supported since Linux v3.12.
59
60``kvm-pv-tlb-flush``
61  Enable paravirtualized TLB flush mechanism. Supported since Linux v4.16.
62
63``kvm-pv-ipi``
64  Enable paravirtualized IPI mechanism. Supported since Linux v4.19.
65
66``kvm-poll-control``
67  Enable host-side polling on HLT control from the guest. Supported since Linux
68  v5.10.
69
70``kvm-pv-sched-yield``
71  Enable paravirtualized sched yield feature. Supported since Linux v5.10.
72
73``kvm-asyncpf-int``
74  Enable interrupt based asynchronous page fault mechanism. Supported since Linux
75  v5.10.
76
77``kvm-msi-ext-dest-id``
78  Support 'Extended Destination ID' for external interrupts. The feature allows
79  to use up to 32768 CPUs without IRQ remapping (but other limits may apply making
80  the number of supported vCPUs for a given configuration lower). Supported since
81  Linux v5.10.
82
83``kvmclock-stable-bit``
84  Tell the guest that guest visible TSC value can be fully trusted for kvmclock
85  computations and no warps are expected. Supported since Linux v2.6.35.
86
87Supplementary features
88----------------------
89
90``kvm-pv-enforce-cpuid``
91  Limit the supported paravirtualized feature set to the exposed features only.
92  Note, by default, ``KVM`` allows the guest to use all currently supported
93  paravirtualized features even when they were not announced in guest visible
94  CPUIDs. Supported since Linux v5.10.
95
96
97Useful links
98------------
99
100Please refer to Documentation/virt/kvm in Linux for additional details.
101