diff options
author | Peter Xu <peterx@redhat.com> | 2021-05-06 12:05:41 -0400 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2021-05-26 14:49:45 +0200 |
commit | a2f77862ffa56b5b0aa9e96fa73620ff751460d5 (patch) | |
tree | a97ef6ff85bd53c1fe615ea296940681e7ea9147 /include/sysemu/kvm_int.h | |
parent | b87eaa9b8237f4d97950ca0f78309407212cfdc5 (diff) | |
download | qemu-a2f77862ffa56b5b0aa9e96fa73620ff751460d5.zip qemu-a2f77862ffa56b5b0aa9e96fa73620ff751460d5.tar.gz qemu-a2f77862ffa56b5b0aa9e96fa73620ff751460d5.tar.bz2 |
KVM: Use a big lock to replace per-kml slots_lock
Per-kml slots_lock will bring some trouble if we want to take all slots_lock of
all the KMLs, especially when we're in a context that we could have taken some
of the KML slots_lock, then we even need to figure out what we've taken and
what we need to take.
Make this simple by merging all KML slots_lock into a single slots lock.
Per-kml slots_lock isn't anything that helpful anyway - so far only x86 has two
address spaces (so, two slots_locks). All the rest archs will be having one
address space always, which means there's actually one slots_lock so it will be
the same as before.
Signed-off-by: Peter Xu <peterx@redhat.com>
Message-Id: <20210506160549.130416-3-peterx@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'include/sysemu/kvm_int.h')
-rw-r--r-- | include/sysemu/kvm_int.h | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/include/sysemu/kvm_int.h b/include/sysemu/kvm_int.h index ccb8869..1da30e1 100644 --- a/include/sysemu/kvm_int.h +++ b/include/sysemu/kvm_int.h @@ -27,8 +27,6 @@ typedef struct KVMSlot typedef struct KVMMemoryListener { MemoryListener listener; - /* Protects the slots and all inside them */ - QemuMutex slots_lock; KVMSlot *slots; int as_id; } KVMMemoryListener; |