]> git.baikalelectronics.ru Git - kernel.git/commit
x86/cpu: Add VM page flush MSR availablility as a CPUID feature
authorTom Lendacky <thomas.lendacky@amd.com>
Thu, 10 Dec 2020 17:09:36 +0000 (11:09 -0600)
committerPaolo Bonzini <pbonzini@redhat.com>
Mon, 14 Dec 2020 16:09:30 +0000 (11:09 -0500)
commit7258e9f85f73456f5a99d1a9bced51636741103b
tree4a60a68a95a4d45ea4b68f1680a8644d142b7ce6
parentbd97c2b6184d12cee4a36841f8fd27c9e75ce670
x86/cpu: Add VM page flush MSR availablility as a CPUID feature

On systems that do not have hardware enforced cache coherency between
encrypted and unencrypted mappings of the same physical page, the
hypervisor can use the VM page flush MSR (0xc001011e) to flush the cache
contents of an SEV guest page. When a small number of pages are being
flushed, this can be used in place of issuing a WBINVD across all CPUs.

CPUID 0x8000001f_eax[2] is used to determine if the VM page flush MSR is
available. Add a CPUID feature to indicate it is supported and define the
MSR.

Signed-off-by: Tom Lendacky <thomas.lendacky@amd.com>
Message-Id: <f1966379e31f9b208db5257509c4a089a87d33d0.1607620209.git.thomas.lendacky@amd.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/include/asm/cpufeatures.h
arch/x86/include/asm/msr-index.h
arch/x86/kernel/cpu/scattered.c