Merge branch 'kvm-lockdep-common' into HEAD
authorPaolo Bonzini <pbonzini@redhat.com>
Tue, 27 May 2025 16:17:06 +0000 (12:17 -0400)
committerPaolo Bonzini <pbonzini@redhat.com>
Wed, 28 May 2025 10:29:17 +0000 (06:29 -0400)
commit8e86e73626527e5a69bf5263d6bbe9c2a86b4319
treed56a6bc701bded71bf3befc233df4f73bd0589a9
parent4e02d4f9734fa55e3eb18be9b759cd42d93497ec
parent4dbe28c0fabd69842890ba38f185b96664cba26a
Merge branch 'kvm-lockdep-common' into HEAD

Introduce new mutex locking functions mutex_trylock_nest_lock() and
mutex_lock_killable_nest_lock() and use them to clean up locking
of all vCPUs for a VM.

For x86, this removes some complex code that was used instead
of lockdep's "nest_lock" feature.

For ARM and RISC-V, this removes a lockdep warning when the VM is
configured to have more than MAX_LOCK_DEPTH vCPUs, and removes a fair
amount of duplicate code by sharing the logic across all architectures.

Signed-off-by: Paolo BOnzini <pbonzini@redhat.com>
arch/x86/kvm/svm/sev.c
include/linux/kvm_host.h
virt/kvm/kvm_main.c