summaryrefslogtreecommitdiff
path: root/rust/helpers/helpers.c
diff options
context:
space:
mode:
authorSean Christopherson <seanjc@google.com>2024-11-07 22:39:59 +0300
committerOliver Upton <oliver.upton@linux.dev>2024-11-11 21:45:29 +0300
commit5afe18dfa47daead88517b095b6e0ce012f031f8 (patch)
tree91f1fdc64fc80021fd42d212022cd4be4c5049fa /rust/helpers/helpers.c
parent38d7aacca09230fdb98a34194fec2af597e8e20d (diff)
downloadlinux-5afe18dfa47daead88517b095b6e0ce012f031f8.tar.xz
KVM: selftests: Don't bother deleting memslots in KVM when freeing VMs
When freeing a VM, don't call into KVM to manually remove each memslot, simply cleanup and free any userspace assets associated with the memory region. KVM is ultimately responsible for ensuring kernel resources are freed when the VM is destroyed, deleting memslots one-by-one is unnecessarily slow, and unless a test is already leaking the VM fd, the VM will be destroyed when kvm_vm_release() is called. Not deleting KVM's memslot also allows cleaning up dead VMs without having to care whether or not the to-be-freed VM is dead or alive. Reported-by: Eric Auger <eric.auger@redhat.com> Reviewed-by: Eric Auger <eric.auger@redhat.com> Tested-by: Eric Auger <eric.auger@redhat.com> Reported-by: Mark Brown <broonie@kernel.org> Signed-off-by: Sean Christopherson <seanjc@google.com> Link: https://lore.kernel.org/kvmarm/Zy0bcM0m-N18gAZz@google.com/ Signed-off-by: Oliver Upton <oliver.upton@linux.dev>
Diffstat (limited to 'rust/helpers/helpers.c')
0 files changed, 0 insertions, 0 deletions