From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:54934) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SS3sM-0001iQ-Gs for qemu-devel@nongnu.org; Wed, 09 May 2012 06:12:12 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SS3sG-0005VY-D5 for qemu-devel@nongnu.org; Wed, 09 May 2012 06:12:06 -0400 Received: from mx1.redhat.com ([209.132.183.28]:4289) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SS3sG-0005VM-4w for qemu-devel@nongnu.org; Wed, 09 May 2012 06:12:00 -0400 Message-ID: <4FAA42EB.2080407@redhat.com> Date: Wed, 09 May 2012 12:11:55 +0200 From: Kevin Wolf MIME-Version: 1.0 References: <4FA97596.4000807@siemens.com> In-Reply-To: <4FA97596.4000807@siemens.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] coroutine-ucontext broken for x86-32 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Jan Kiszka Cc: Anthony Liguori , Michael Tokarev , qemu-devel Am 08.05.2012 21:35, schrieb Jan Kiszka: > Hi, > > I hunted down a fairly subtle corruption of the VCPU thread signal mask > in KVM mode when using the ucontext version of coroutines: > > coroutine_new calls getcontext, makecontext, swapcontext. Those > functions get/set also the signal mask of the caller. Unfortunately, > they only use the sigprocmask syscall on i386, not the rt_sigprocmask > version. So they do not properly save/restore the blocked RT signals, > namely our SIG_IPI - it becomes unblocke this way. If other coroutine backends work (sigaltstack?), we could try to detect the situation in configure and set the right default. Not sure what the condition is, glibc + i386? Kevin