KVM: Add kvm_arch_sync_events to sync with asynchronize events
authorSheng Yang <sheng@linux.intel.com>
Tue, 6 Jan 2009 02:03:02 +0000 (10:03 +0800)
committerAvi Kivity <avi@redhat.com>
Sun, 15 Feb 2009 00:47:36 +0000 (02:47 +0200)
commitad8ba2cd44d4d39fb3fe55d5dcc565b19fc3a7fb
tree74dfd501fc541b7d55eecec7b9469f1db8225507
parent85db06e514422ae429b5f85742d8111b70bd56f3
KVM: Add kvm_arch_sync_events to sync with asynchronize events

kvm_arch_sync_events is introduced to quiet down all other events may happen
contemporary with VM destroy process, like IRQ handler and work struct for
assigned device.

For kvm_arch_sync_events is called at the very beginning of kvm_destroy_vm(), so
the state of KVM here is legal and can provide a environment to quiet down other
events.

Signed-off-by: Sheng Yang <sheng@linux.intel.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
arch/ia64/kvm/kvm-ia64.c
arch/powerpc/kvm/powerpc.c
arch/s390/kvm/kvm-s390.c
arch/x86/kvm/x86.c
include/linux/kvm_host.h
virt/kvm/kvm_main.c