arch: hyperv: Get/set SynIC synth.registers via paravisor
authorRoman Kisel <romank@linux.microsoft.com>
Wed, 8 Oct 2025 23:34:06 +0000 (16:34 -0700)
committerWei Liu <wei.liu@kernel.org>
Sat, 15 Nov 2025 06:18:14 +0000 (06:18 +0000)
commite6eeb3c782739cd1613a8da856b878b99f741943
tree7f6735d4c3f38525b5288f82d1f8fd3fe3bea067
parent7c8b6c326d830ca5c6b95f390c703966e14167e6
arch: hyperv: Get/set SynIC synth.registers via paravisor

The existing Hyper-V wrappers for getting and setting MSRs are
hv_get/set_msr(). Via hv_get/set_non_nested_msr(), they detect
when running in a CoCo VM with a paravisor, and use the TDX or
SNP guest-host communication protocol to bypass the paravisor
and go directly to the host hypervisor for SynIC MSRs. The "set"
function also implements the required special handling for the
SINT MSRs.

Provide functions that allow manipulating the SynIC registers
through the paravisor. Move vmbus_signal_eom() to a more
appropriate location (which also avoids breaking KVM).

Signed-off-by: Roman Kisel <romank@linux.microsoft.com>
Reviewed-by: Alok Tiwari <alok.a.tiwari@oracle.com>
Reviewed-by: Michael Kelley <mhklinux@outlook.com>
Signed-off-by: Wei Liu <wei.liu@kernel.org>
arch/x86/kernel/cpu/mshyperv.c
drivers/hv/hv_common.c
drivers/hv/hyperv_vmbus.h
include/asm-generic/mshyperv.h