Browse Source

KVM: Fix memory leak on guest exit

This patch fixes a memory leak, we want to free the physmem when destroying
the vm.

Signed-off-by: Carsten Otte <cotte@de.ibm.com>
Signed-off-by: Avi Kivity <avi@qumranet.com>
Carsten Otte 17 years ago
parent
commit
dfdded7c41
1 changed files with 1 additions and 0 deletions
  1. 1 0
      arch/s390/kvm/kvm-s390.c

+ 1 - 0
arch/s390/kvm/kvm-s390.c

@@ -194,6 +194,7 @@ out_nokvm:
 void kvm_arch_destroy_vm(struct kvm *kvm)
 {
 	debug_unregister(kvm->arch.dbf);
+	kvm_free_physmem(kvm);
 	free_page((unsigned long)(kvm->arch.sca));
 	kfree(kvm);
 	module_put(THIS_MODULE);