Re: [PATCH v2] Documentation: KVM: Formalizing taking vcpu->mutex *outside* of kvm->slots_lock
From: Sean Christopherson
Date: Thu Mar 05 2026 - 12:10:20 EST
On Mon, 02 Mar 2026 09:02:39 -0800, Sean Christopherson wrote:
> Explicitly document the ordering of vcpu->mutex being taken *outside* of
> kvm->slots_lock. While somewhat unintuitive since vCPUs conceptually have
> narrower scope than VMs, the scope of the owning object (vCPU versus VM)
> doesn't automatically carry over to the lock. In this case, vcpu->mutex
> has far broader scope than kvm->slots_lock. As Paolo put it, it's a
> "don't worry about multiple ioctls at the same time" mutex that's intended
> to be taken at the outer edges of KVM.
>
> [...]
Applied to kvm-x86 generic.
[1/1] Documentation: KVM: Formalizing taking vcpu->mutex *outside* of kvm->slots_lock
https://github.com/kvm-x86/linux/commit/f8211e95dfda
--
https://github.com/kvm-x86/linux/tree/next