[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 2/2] kvm: exit to userspace with reason KVM_EXIT
From: |
Gleb Natapov |
Subject: |
Re: [Qemu-devel] [PATCH 2/2] kvm: exit to userspace with reason KVM_EXIT_VCPU_DEAD |
Date: |
Sun, 27 Nov 2011 12:50:00 +0200 |
On Sun, Nov 27, 2011 at 12:36:55PM +0200, Avi Kivity wrote:
> On 11/27/2011 04:42 AM, Liu Ping Fan wrote:
> > From: Liu Ping Fan <address@hidden>
> >
> > The vcpu can be safely released when
> > --1.guest tells us that the vcpu is not needed any longer.
> > --2.vcpu hits the last instruction _halt_
> >
> > If both of the conditions are satisfied, kvm exits to userspace
> > with the reason vcpu dead. So the user thread can exit safely.
> >
> >
>
> Seems to be completely unnecessary. If you want to exit from the vcpu
> thread, send it a signal.
>
Also if guest "tells us that the vcpu is not needed any longer" (via
ACPI I presume) and vcpu actually doing something critical instead of
sitting in 1:hlt; jmp 1b loop then it is guest's problem if it stops
working after vcpu destruction.
--
Gleb.
[Qemu-devel] [PATCH 1/5] QEMU Add cpu_phyid_to_cpu() to map cpu phyid to CPUState, Liu Ping Fan, 2011/11/26
[Qemu-devel] [PATCH 2/5] QEMU Add cpu_free() to support arch related CPUState release, Liu Ping Fan, 2011/11/26
[Qemu-devel] [PATCH 3/5] QEMU Introduce a pci device "cpustate" to get CPU_DEAD event in guest, Liu Ping Fan, 2011/11/26
[Qemu-devel] [PATCH 4/5] QEMU Release vcpu and finally exit vcpu thread safely, Liu Ping Fan, 2011/11/26
[Qemu-devel] [PATCH 5/5] QEMU tmp patches for linux-header files, Liu Ping Fan, 2011/11/26
[Qemu-devel] [PATCH] virtio: add a pci driver to notify host the CPU_DEAD event, Liu Ping Fan, 2011/11/26