From: Marcelo Tosatti <[EMAIL PROTECTED]> This fixes the slow vmdk issue found in the regression tests.
Signed-off-by: Marcelo Tosatti <[EMAIL PROTECTED]> Signed-off-by: Avi Kivity <[EMAIL PROTECTED]> diff --git a/qemu/qemu-kvm.c b/qemu/qemu-kvm.c index 7bf7aa3..8b5d2dc 100644 --- a/qemu/qemu-kvm.c +++ b/qemu/qemu-kvm.c @@ -411,6 +411,12 @@ int kvm_init_ap(void) return 0; } +void qemu_kvm_notify_work(void) +{ + if (io_thread) + pthread_kill(io_thread, SIGUSR1); +} + /* * The IO thread has all signals that inform machine events * blocked (io_signal_table), so it won't get interrupted diff --git a/qemu/qemu-kvm.h b/qemu/qemu-kvm.h index ff9c86e..ae5ce1a 100644 --- a/qemu/qemu-kvm.h +++ b/qemu/qemu-kvm.h @@ -60,6 +60,8 @@ void qemu_kvm_aio_wait_start(void); void qemu_kvm_aio_wait(void); void qemu_kvm_aio_wait_end(void); +void qemu_kvm_notify_work(void); + void kvm_tpr_opt_setup(); void kvm_tpr_access_report(CPUState *env, uint64_t rip, int is_write); int handle_tpr_access(void *opaque, int vcpu, diff --git a/qemu/vl.c b/qemu/vl.c index 8cb827b..49d9af2 100644 --- a/qemu/vl.c +++ b/qemu/vl.c @@ -7588,6 +7588,8 @@ void qemu_bh_schedule(QEMUBH *bh) if (env) { cpu_interrupt(env, CPU_INTERRUPT_EXIT); } + if (kvm_enabled()) + qemu_kvm_notify_work(); } void qemu_bh_cancel(QEMUBH *bh) ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace _______________________________________________ kvm-commits mailing list kvm-commits@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/kvm-commits