]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
KVM: Assert that slots_lock is held when resetting per-vCPU dirty rings
authorSean Christopherson <seanjc@google.com>
Fri, 16 May 2025 21:35:40 +0000 (14:35 -0700)
committerSean Christopherson <seanjc@google.com>
Fri, 20 Jun 2025 20:41:04 +0000 (13:41 -0700)
commit614fb9d1479b1d90721ca70da8b7c55f69fe9ad2
tree7a1835eccd50d8c0489c64218864105a71e1ab7f
parente46ad851150f1dd14b8542b6fb7a51f695a99eb1
KVM: Assert that slots_lock is held when resetting per-vCPU dirty rings

Assert that slots_lock is held in kvm_dirty_ring_reset() and add a comment
to explain _why_ slots needs to be held for the duration of the reset.

Link: https://lore.kernel.org/all/aCSns6Q5oTkdXUEe@google.com
Suggested-by: James Houghton <jthoughton@google.com>
Reviewed-by: Yan Zhao <yan.y.zhao@intel.com>
Reviewed-by: Peter Xu <peterx@redhat.com>
Link: https://lore.kernel.org/r/20250516213540.2546077-7-seanjc@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
virt/kvm/dirty_ring.c