forked from torvalds/linux
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm
Pull KVM updates from Paolo Bonzini: "ARM: - support for chained PMU counters in guests - improved SError handling - handle Neoverse N1 erratum #1349291 - allow side-channel mitigation status to be migrated - standardise most AArch64 system register accesses to msr_s/mrs_s - fix host MPIDR corruption on 32bit - selftests ckleanups x86: - PMU event {white,black}listing - ability for the guest to disable host-side interrupt polling - fixes for enlightened VMCS (Hyper-V pv nested virtualization), - new hypercall to yield to IPI target - support for passing cstate MSRs through to the guest - lots of cleanups and optimizations Generic: - Some txt->rST conversions for the documentation" * tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm: (128 commits) Documentation: virtual: Add toctree hooks Documentation: kvm: Convert cpuid.txt to .rst Documentation: virtual: Convert paravirt_ops.txt to .rst KVM: x86: Unconditionally enable irqs in guest context KVM: x86: PMU Event Filter kvm: x86: Fix -Wmissing-prototypes warnings KVM: Properly check if "page" is valid in kvm_vcpu_unmap KVM: arm/arm64: Initialise host's MPIDRs by reading the actual register KVM: LAPIC: Retry tune per-vCPU timer_advance_ns if adaptive tuning goes insane kvm: LAPIC: write down valid APIC registers KVM: arm64: Migrate _elx sysreg accessors to msr_s/mrs_s KVM: doc: Add API documentation on the KVM_REG_ARM_WORKAROUNDS register KVM: arm/arm64: Add save/restore support for firmware workaround state arm64: KVM: Propagate full Spectre v2 workaround state to KVM guests KVM: arm/arm64: Support chained PMU counters KVM: arm/arm64: Remove pmc->bitmask KVM: arm/arm64: Re-create event when setting counter value KVM: arm/arm64: Extract duplicated code to own function KVM: arm/arm64: Rename kvm_pmu_{enable/disable}_counter functions KVM: LAPIC: ARBPRI is a reserved register for x2APIC ...
- Loading branch information
Showing
92 changed files
with
2,693 additions
and
1,432 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
.. SPDX-License-Identifier: GPL-2.0 | ||
============================ | ||
Linux Virtualization Support | ||
============================ | ||
|
||
.. toctree:: | ||
:maxdepth: 2 | ||
|
||
kvm/index | ||
paravirt_ops | ||
|
||
.. only:: html and subproject | ||
|
||
Indices | ||
======= | ||
|
||
* :ref:`genindex` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,107 @@ | ||
.. SPDX-License-Identifier: GPL-2.0 | ||
============== | ||
KVM CPUID bits | ||
============== | ||
|
||
:Author: Glauber Costa <glommer@gmail.com> | ||
|
||
A guest running on a kvm host, can check some of its features using | ||
cpuid. This is not always guaranteed to work, since userspace can | ||
mask-out some, or even all KVM-related cpuid features before launching | ||
a guest. | ||
|
||
KVM cpuid functions are: | ||
|
||
function: KVM_CPUID_SIGNATURE (0x40000000) | ||
|
||
returns:: | ||
|
||
eax = 0x40000001 | ||
ebx = 0x4b4d564b | ||
ecx = 0x564b4d56 | ||
edx = 0x4d | ||
|
||
Note that this value in ebx, ecx and edx corresponds to the string "KVMKVMKVM". | ||
The value in eax corresponds to the maximum cpuid function present in this leaf, | ||
and will be updated if more functions are added in the future. | ||
Note also that old hosts set eax value to 0x0. This should | ||
be interpreted as if the value was 0x40000001. | ||
This function queries the presence of KVM cpuid leafs. | ||
|
||
function: define KVM_CPUID_FEATURES (0x40000001) | ||
|
||
returns:: | ||
|
||
ebx, ecx | ||
eax = an OR'ed group of (1 << flag) | ||
|
||
where ``flag`` is defined as below: | ||
|
||
================================= =========== ================================ | ||
flag value meaning | ||
================================= =========== ================================ | ||
KVM_FEATURE_CLOCKSOURCE 0 kvmclock available at msrs | ||
0x11 and 0x12 | ||
|
||
KVM_FEATURE_NOP_IO_DELAY 1 not necessary to perform delays | ||
on PIO operations | ||
|
||
KVM_FEATURE_MMU_OP 2 deprecated | ||
|
||
KVM_FEATURE_CLOCKSOURCE2 3 kvmclock available at msrs | ||
|
||
0x4b564d00 and 0x4b564d01 | ||
KVM_FEATURE_ASYNC_PF 4 async pf can be enabled by | ||
writing to msr 0x4b564d02 | ||
|
||
KVM_FEATURE_STEAL_TIME 5 steal time can be enabled by | ||
writing to msr 0x4b564d03 | ||
|
||
KVM_FEATURE_PV_EOI 6 paravirtualized end of interrupt | ||
handler can be enabled by | ||
writing to msr 0x4b564d04 | ||
|
||
KVM_FEATURE_PV_UNHAULT 7 guest checks this feature bit | ||
before enabling paravirtualized | ||
spinlock support | ||
|
||
KVM_FEATURE_PV_TLB_FLUSH 9 guest checks this feature bit | ||
before enabling paravirtualized | ||
tlb flush | ||
|
||
KVM_FEATURE_ASYNC_PF_VMEXIT 10 paravirtualized async PF VM EXIT | ||
can be enabled by setting bit 2 | ||
when writing to msr 0x4b564d02 | ||
|
||
KVM_FEATURE_PV_SEND_IPI 11 guest checks this feature bit | ||
before enabling paravirtualized | ||
sebd IPIs | ||
|
||
KVM_FEATURE_PV_POLL_CONTROL 12 host-side polling on HLT can | ||
be disabled by writing | ||
to msr 0x4b564d05. | ||
|
||
KVM_FEATURE_PV_SCHED_YIELD 13 guest checks this feature bit | ||
before using paravirtualized | ||
sched yield. | ||
|
||
KVM_FEATURE_CLOCSOURCE_STABLE_BIT 24 host will warn if no guest-side | ||
per-cpu warps are expeced in | ||
kvmclock | ||
================================= =========== ================================ | ||
|
||
:: | ||
|
||
edx = an OR'ed group of (1 << flag) | ||
|
||
Where ``flag`` here is defined as below: | ||
|
||
================== ============ ================================= | ||
flag value meaning | ||
================== ============ ================================= | ||
KVM_HINTS_REALTIME 0 guest checks this feature bit to | ||
determine that vCPUs are never | ||
preempted for an unlimited time | ||
allowing optimizations | ||
================== ============ ================================= |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
.. SPDX-License-Identifier: GPL-2.0 | ||
=== | ||
KVM | ||
=== | ||
|
||
.. toctree:: | ||
:maxdepth: 2 | ||
|
||
amd-memory-encryption | ||
cpuid |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.