* [PATCH] remove SIGUSR2 from io_sigset to avoid breaking AIO
@ 2008-01-14 11:48 Liu, Eric E
[not found] ` <9D7649D18729DE4BB2BD7B494F7FEDC2D7234E-wq7ZOvIWXbMAbVU2wMM1CrfspsVTdybXVpNB7YpNyf8@public.gmane.org>
0 siblings, 1 reply; 2+ messages in thread
From: Liu, Eric E @ 2008-01-14 11:48 UTC (permalink / raw)
To: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f
[-- Attachment #1: Type: text/plain, Size: 1588 bytes --]
If we use Qcow img to boot SMP guest, windows guest may hang , since
the vcpu thread which does AIO will wait for the signal SIGUSR2 which
may be eated by vcpu 0 's thread. So this patch removes SIGUSR2 from
io_sigset and masks it in vcpu 0's thread, it can let the guest boot
successfully.
>From e8e97f71c6e67daae57cecef369167f65aae8b9c Mon Sep 17 00:00:00 2001
From: Feng (Eric) Liu <eric.e.liu-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
Date: Tue, 15 Jan 2008 12:05:37 -0500
Subject: [PATCH] kvm: qemu: remove SIGUSR2 from io_sigset
To avoid breaking Aio with qcow, remove SIGUSR2 from io_sigset, and
mask it in all vcpu's threads.
Signed-off-by: Feng (Eric) Liu <eric.e.liu-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
---
qemu/qemu-kvm.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/qemu/qemu-kvm.c b/qemu/qemu-kvm.c
index dd84686..063d14f 100644
--- a/qemu/qemu-kvm.c
+++ b/qemu/qemu-kvm.c
@@ -310,9 +310,10 @@ static void setup_kernel_sigmask(CPUState *env)
sigprocmask(SIG_BLOCK, NULL, &set);
sigdelset(&set, SIG_IPI);
- if (env->cpu_index == 0)
+ if (env->cpu_index == 0) {
+ sigaddset(&set, SIGUSR2);
sigandset(&set, &set, &io_negsigset);
-
+ }
kvm_set_signal_mask(kvm_context, env->cpu_index, &set);
}
@@ -391,7 +392,6 @@ int kvm_init_ap(void)
sigfillset(&io_negsigset);
kvm_add_signal(SIGIO);
kvm_add_signal(SIGALRM);
- kvm_add_signal(SIGUSR2);
if (!kvm_irqchip_in_kernel(kvm_context))
kvm_add_signal(SIG_IPI);
--Eric (Liu, Feng)
[-- Attachment #2: 0001-kvm-qemu-remove-SIGUSR2-from-io_sigset.patch --]
[-- Type: application/octet-stream, Size: 1182 bytes --]
From e8e97f71c6e67daae57cecef369167f65aae8b9c Mon Sep 17 00:00:00 2001
From: Feng (Eric) Liu <eric.e.liu@intel.com>
Date: Tue, 15 Jan 2008 12:05:37 -0500
Subject: [PATCH] kvm: qemu: remove SIGUSR2 from io_sigset
To avoid breaking Aio with qcow, remove SIGUSR2 from io_sigset, and
mask it in all vcpu's threads.
Signed-off-by: Feng (Eric) Liu <eric.e.liu@intel.com>
---
qemu/qemu-kvm.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/qemu/qemu-kvm.c b/qemu/qemu-kvm.c
index dd84686..063d14f 100644
--- a/qemu/qemu-kvm.c
+++ b/qemu/qemu-kvm.c
@@ -310,9 +310,10 @@ static void setup_kernel_sigmask(CPUState *env)
sigprocmask(SIG_BLOCK, NULL, &set);
sigdelset(&set, SIG_IPI);
- if (env->cpu_index == 0)
+ if (env->cpu_index == 0) {
+ sigaddset(&set, SIGUSR2);
sigandset(&set, &set, &io_negsigset);
-
+ }
kvm_set_signal_mask(kvm_context, env->cpu_index, &set);
}
@@ -391,7 +392,6 @@ int kvm_init_ap(void)
sigfillset(&io_negsigset);
kvm_add_signal(SIGIO);
kvm_add_signal(SIGALRM);
- kvm_add_signal(SIGUSR2);
if (!kvm_irqchip_in_kernel(kvm_context))
kvm_add_signal(SIG_IPI);
--
1.5.1
[-- Attachment #3: Type: text/plain, Size: 278 bytes --]
-------------------------------------------------------------------------
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
[-- Attachment #4: Type: text/plain, Size: 186 bytes --]
_______________________________________________
kvm-devel mailing list
kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
https://lists.sourceforge.net/lists/listinfo/kvm-devel
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-01-15 14:10 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-01-14 11:48 [PATCH] remove SIGUSR2 from io_sigset to avoid breaking AIO Liu, Eric E
[not found] ` <9D7649D18729DE4BB2BD7B494F7FEDC2D7234E-wq7ZOvIWXbMAbVU2wMM1CrfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2008-01-15 14:10 ` Avi Kivity
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox