linux/arch/powerpc
Nicholas Piggin dc158d23b3 KVM: PPC: Book3S HV: Fix KVM_RUN clobbering FP/VEC user registers
Before running a guest, the host process (e.g., QEMU) FP/VEC registers
are saved if they were being used, similarly to when the kernel uses FP
registers. The guest values are then loaded into regs, and the host
process registers will be restored lazily when it uses FP/VEC.

KVM HV has a bug here: the host process registers do get saved, but the
user MSR bits remain enabled, which indicates the registers are valid
for the process. After they are clobbered by running the guest, this
valid indication causes the host process to take on the FP/VEC register
values of the guest.

Fixes: 34e119c96b ("KVM: PPC: Book3S HV P9: Reduce mtmsrd instructions required to save host SPRs")
Cc: stable@vger.kernel.org # v5.17+
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://msgid.link/20231122025811.2973-1-npiggin@gmail.com
2023-11-29 22:24:21 +11:00
..
boot powerpc/boot: Add version to install filenames 2023-10-20 17:34:26 +11:00
configs powerpc updates for 6.7 2023-11-03 10:07:39 -10:00
crypto
include powerpc fixes for 6.7 #2 2023-11-12 10:50:38 -08:00
kernel KVM: PPC: Book3S HV: Fix KVM_RUN clobbering FP/VEC user registers 2023-11-29 22:24:21 +11:00
kexec powerpc updates for 6.7 2023-11-03 10:07:39 -10:00
kvm powerpc updates for 6.7 2023-11-03 10:07:39 -10:00
lib powerpc/code-patching: introduce patch_instructions() 2023-10-23 20:33:19 +11:00
math-emu
mm powerpc: Remove file parameter from phys_mem_access_prot() 2023-11-06 15:21:33 +11:00
net powerpc/bpf: use bpf_jit_binary_pack_[alloc|finalize|free] 2023-10-23 20:33:19 +11:00
perf powerpc/perf: Fix disabling BHRB and instruction sampling 2023-10-20 22:40:20 +11:00
platforms powerpc/pseries/rtas-work-area: Fix rtas_work_area_reserve_arena() kernel-doc 2023-11-07 13:13:44 +11:00
purgatory
sysdev powerpc/fsl_msi: Use device_get_match_data() 2023-10-20 23:18:34 +11:00
tools powerpc/tools: Pass -mabi=elfv2 to gcc-check-mprofile-kernel.sh 2023-10-20 17:46:33 +11:00
xmon
Kbuild
Kconfig powerpc/trace: Add support for HAVE_FUNCTION_ARG_ACCESS_API 2023-10-20 17:55:56 +11:00
Kconfig.debug Merge branch 'topic/ppc-kvm' into next 2023-10-27 20:58:03 +11:00
Makefile
Makefile.postlink kbuild: remove ARCH_POSTLINK from module builds 2023-10-28 21:10:08 +09:00