Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1377343
| From | Paolo Bonzini <pbonzini@redhat.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PART1 RFC v4 02/11] KVM: x86: Introducing kvm_x86_ops VM init/uninit hooks |
| Date | 2016-04-13 00:00 +0200 |
| Message-ID | <rnevN-67f-19@gated-at.bofh.it> (permalink) |
| References | <rldu9-10J-3@gated-at.bofh.it> <rldu9-10J-1@gated-at.bofh.it> <rmQWu-3to-9@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On 11/04/2016 22:49, Radim Krčmář wrote: >> > @@ -7781,6 +7784,9 @@ static void kvm_free_vcpus(struct kvm *kvm) >> > kvm_for_each_vcpu(i, vcpu, kvm) >> > kvm_arch_vcpu_free(vcpu); >> > >> > + if (kvm_x86_ops->vm_uninit) >> > + kvm_x86_ops->vm_uninit(kvm); > vm_uninit() doesn't seem to have much to do with kvm_free_vcpus(), > please call it from kvm_arch_destroy_vm(). > > (kvm_x86_ops.vm_destroy would be a better name then.) Especially, you're calling it with struct kvm full of dangling pointer, so please call it early, right after the "if (current->mm == kvm->mm)" block. Paolo
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
[PART1 RFC v4 02/11] KVM: x86: Introducing kvm_x86_ops VM init/uninit hooks Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> - 2016-04-07 10:30 +0200
Re: [PART1 RFC v4 02/11] KVM: x86: Introducing kvm_x86_ops VM init/uninit hooks Radim Krčmář <rkrcmar@redhat.com> - 2016-04-11 22:50 +0200
Re: [PART1 RFC v4 02/11] KVM: x86: Introducing kvm_x86_ops VM init/uninit hooks Paolo Bonzini <pbonzini@redhat.com> - 2016-04-13 00:00 +0200
csiph-web