Re: [PATCH] KVM: x86/mmu: Refresh CR0.WP prior to checking for emulated permission faults

From: Sean Christopherson
Date: Mon Apr 10 2023 - 19:30:32 EST


On Tue, 04 Apr 2023 17:26:08 -0700, Sean Christopherson wrote:
> If CR0.WP may be guest-owned, i.e. TDP is enabled, refresh the MMU's
> snapshot of the guest's CR0.WP prior to checking for permission faults
> when emulating a guest memory access. If the guest toggles only CR0.WP
> and triggers emulation of a supervisor write, e.g. when KVM is emulating
> UMIP, KVM may consume a stale CR0.WP, i.e. use stale protection bits
> metadata.
>
> [...]

Applied to kvm-x86 misc, with a reworked changelog.

[1/1] KVM: x86/mmu: Refresh CR0.WP prior to checking for emulated permission faults
https://github.com/kvm-x86/linux/commit/cf9f4c0eb169

--
https://github.com/kvm-x86/linux/tree/next
https://github.com/kvm-x86/linux/tree/fixes