Re: [PATCH v2] i386/kvm: fix a use-after-free when vcpu plug/unplug

2020-05-21 Thread Paolo Bonzini
On 13/05/20 15:26, Pan Nengyuan wrote: > When we hotplug vcpus, cpu_update_state is added to vm_change_state_head > in kvm_arch_init_vcpu(). But it forgot to delete in kvm_arch_destroy_vcpu() > after > unplug. Then it will cause a use-after-free access. This patch delete it in > kvm_arch_destroy_v

Re: [PATCH v2] i386/kvm: fix a use-after-free when vcpu plug/unplug

2020-05-13 Thread Igor Mammedov
On Wed, 13 May 2020 09:26:30 -0400 Pan Nengyuan wrote: > When we hotplug vcpus, cpu_update_state is added to vm_change_state_head > in kvm_arch_init_vcpu(). But it forgot to delete in kvm_arch_destroy_vcpu() > after > unplug. Then it will cause a use-after-free access. This patch delete it in >

[PATCH v2] i386/kvm: fix a use-after-free when vcpu plug/unplug

2020-05-13 Thread Pan Nengyuan
When we hotplug vcpus, cpu_update_state is added to vm_change_state_head in kvm_arch_init_vcpu(). But it forgot to delete in kvm_arch_destroy_vcpu() after unplug. Then it will cause a use-after-free access. This patch delete it in kvm_arch_destroy_vcpu() to fix that. Reproducer: virsh setvcpu