From: Avi Kivity <avi@redhat.com>
To: kvm-ia64@vger.kernel.org
Subject: Re: [PATCH] kvm/ia64: Ensure SIGINT delivered to main thread (vcpu
Date: Mon, 20 Oct 2008 07:23:48 +0000 [thread overview]
Message-ID: <48FC3204.4030902@redhat.com> (raw)
In-Reply-To: <42DFA526FC41B1429CE7279EF83C6BDC01B489F8@pdsmsx415.ccr.corp.intel.com>
Zhang, Xiantao wrote:
> Before Aps going to block status, it should make sure SIGINT is
> masked, otherwise, it may eat SIGINT from user killing the guest, and
> results in Qemu hanging there, becasue main thread can't get it to free
> guest's resource.
>
> vcpu_load(vcpu);
>
> + if (vcpu->sigset_active)
> + sigprocmask(SIG_SETMASK, &vcpu->sigset, &sigsaved);
> +
> if (unlikely(vcpu->arch.mp_state = KVM_MP_STATE_UNINITIALIZED))
> {
> kvm_vcpu_block(vcpu);
> clear_bit(KVM_REQ_UNHALT, &vcpu->requests);
> @@ -680,9 +683,6 @@ int kvm_arch_vcpu_ioctl_run(struct kvm_vcpu *vcpu,
> struct kvm_run *kvm_run)
> return -EAGAIN;
>
The 'return' here means you are returning with the wrong signal mask.
> }
>
> - if (vcpu->sigset_active)
> - sigprocmask(SIG_SETMASK, &vcpu->sigset, &sigsaved);
> -
> if (vcpu->mmio_needed) {
> memcpy(vcpu->mmio_data, kvm_run->mmio.data, 8);
> kvm_set_mmio_data(vcpu);
>
--
I have a truly marvellous patch that fixes the bug which this
signature is too narrow to contain.
next prev parent reply other threads:[~2008-10-20 7:23 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-20 5:58 [PATCH] kvm/ia64: Ensure SIGINT delivered to main thread (vcpu 0) Zhang, Xiantao
2008-10-20 7:23 ` Avi Kivity [this message]
2008-10-20 8:08 ` Zhang, Xiantao
2008-10-20 8:43 ` [PATCH] kvm/ia64: Ensure SIGINT delivered to main thread (vcpu Avi Kivity
2008-10-20 9:03 ` [PATCH] kvm/ia64: Ensure SIGINT delivered to main thread (vcpu 0) Zhang, Xiantao
2008-10-22 3:13 ` Zhang, Xiantao
2008-10-22 10:47 ` [PATCH] kvm/ia64: Ensure SIGINT delivered to main thread (vcpu Avi Kivity
2008-10-23 2:00 ` Zhang, Xiantao
2008-10-23 4:31 ` Avi Kivity
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=48FC3204.4030902@redhat.com \
--to=avi@redhat.com \
--cc=kvm-ia64@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox