Re: [PATCH] KVM: PPC: Book3S HV: Fix KVM_RUN clobbering FP/VEC user registers
From: Michael Ellerman <hidden>
Date: 2023-12-02 23:03:21
From: Michael Ellerman <hidden>
Date: 2023-12-02 23:03:21
On Wed, 22 Nov 2023 12:58:11 +1000, Nicholas Piggin wrote:
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 be 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 regiter values of the guest. [...]
Applied to powerpc/fixes.
[1/1] KVM: PPC: Book3S HV: Fix KVM_RUN clobbering FP/VEC user registers
https://git.kernel.org/powerpc/c/dc158d23b33df9033bcc8e7117e8591dd2f9d125
cheers