diff options
author | Vitaly Kuznetsov <vkuznets@redhat.com> | 2018-01-24 13:36:29 +0300 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2018-01-25 11:40:59 +0300 |
commit | 617ab45c9a8900e64a78b43696c02598b8cad68b (patch) | |
tree | 85e73eb01c3482c488c6bd0dc8fdb52fe36cc01c /arch/x86/include/asm/intel_punit_ipc.h | |
parent | 1f07476ec143bbed7bf0b641749783b1094b4c4f (diff) | |
download | linux-617ab45c9a8900e64a78b43696c02598b8cad68b.tar.xz |
x86/hyperv: Stop suppressing X86_FEATURE_PCID
When hypercall-based TLB flush was enabled for Hyper-V guests PCID feature
was deliberately suppressed as a precaution: back then PCID was never
exposed to Hyper-V guests and it wasn't clear what will happen if some day
it becomes available. The day came and PCID/INVPCID features are already
exposed on certain Hyper-V hosts.
From TLFS (as of 5.0b) it is unclear how TLB flush hypercalls combine with
PCID. In particular the usage of PCID is per-cpu based: the same mm gets
different CR3 values on different CPUs. If the hypercall does exact
matching this will fail. However, this is not the case. David Zhang
explains:
"In practice, the AddressSpace argument is ignored on any VM that supports
PCIDs.
Architecturally, the AddressSpace argument must match the CR3 with PCID
bits stripped out (i.e., the low 12 bits of AddressSpace should be 0 in
long mode). The flush hypercalls flush all PCIDs for the specified
AddressSpace."
With this, PCID can be enabled.
Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: David Zhang <dazhan@microsoft.com>
Cc: Stephen Hemminger <sthemmin@microsoft.com>
Cc: Haiyang Zhang <haiyangz@microsoft.com>
Cc: "Michael Kelley (EOSG)" <Michael.H.Kelley@microsoft.com>
Cc: Andy Lutomirski <luto@kernel.org>
Cc: devel@linuxdriverproject.org
Cc: "K. Y. Srinivasan" <kys@microsoft.com>
Cc: Aditya Bhandari <adityabh@microsoft.com>
Link: https://lkml.kernel.org/r/20180124103629.29980-1-vkuznets@redhat.com
Diffstat (limited to 'arch/x86/include/asm/intel_punit_ipc.h')
0 files changed, 0 insertions, 0 deletions