From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1I8gR6-0001Fl-OZ for qemu-devel@nongnu.org; Wed, 11 Jul 2007 13:57:12 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1I8gR6-0001FG-Fc for qemu-devel@nongnu.org; Wed, 11 Jul 2007 13:57:12 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1I8gR6-0001FD-61 for qemu-devel@nongnu.org; Wed, 11 Jul 2007 13:57:12 -0400 Received: from an-out-0708.google.com ([209.85.132.241]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1I8gR5-000311-Li for qemu-devel@nongnu.org; Wed, 11 Jul 2007 13:57:11 -0400 Received: by an-out-0708.google.com with SMTP id d11so502728and for ; Wed, 11 Jul 2007 10:57:11 -0700 (PDT) Message-ID: Date: Wed, 11 Jul 2007 10:57:10 -0700 From: "Yigael Fleishman" Subject: Re: [Qemu-devel] Missing system calls retries in case of EINTR In-Reply-To: <200707111304.33631.rob@landley.net> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_6853_18313260.1184176630691" References: <200707061457.07925.rob@landley.net> <200707111304.33631.rob@landley.net> Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Rob Landley Cc: qemu-devel@nongnu.org, frederic.roussel@access-company.com ------=_Part_6853_18313260.1184176630691 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline Rob Thanks for the background info. I wasn't very specific in my last question. Actually I meant to ask why doesn't qemu code set sigaction(SA_RESTART) for _all_ signals when running in system emulation mode (or maybe it does, which means there's even larger problem...) --Yigael On 7/11/07, Rob Landley wrote: > > Talking about sigaction(SA_RESTART) vs looping around -EINTR everywhere: > > On Tuesday 10 July 2007 8:57:34 pm Yigael Fleishman wrote: > > Rob, > > Thanks, that should also work. > > Seems do_sigaction() in linux-user/signal.c has some code which does > that > > (though obviously not for the signal that I'm receiving). > > Any idea why SA_RESTART calls are not invoked by default to restart > > syscalls for all signals? > > Fallout from old 1980's-era Unixes that didn't implement SA_RESTART, > basically. Standards like SUSv3 say to humor them, because they paid for > the > standard... > > http://www.ussg.iu.edu/hypermail/linux/kernel/0507.1/1065.html > > > --Yigael > > Rob > -- > "One of my most productive days was throwing away 1000 lines of code." > - Ken Thompson. > ------=_Part_6853_18313260.1184176630691 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline Rob
Thanks for the background info. I wasn't very specific in my last question. Actually I meant to ask why doesn't qemu code set sigaction(SA_RESTART) for _all_ signals when running in system emulation mode (or maybe it does, which means there's even larger problem...)
--Yigael




On 7/11/07, Rob Landley <rob@landley.net> wrote:
Talking about sigaction(SA_RESTART) vs looping around -EINTR everywhere:

On Tuesday 10 July 2007 8:57:34 pm Yigael Fleishman wrote:
> Rob,
> Thanks, that should also work.
> Seems do_sigaction() in linux-user/signal.c has some code which does that
> (though obviously not for the signal that I'm receiving).
> Any idea why SA_RESTART calls are not invoked by default to restart
> syscalls for all signals?

Fallout from old 1980's-era Unixes that didn't implement SA_RESTART,
basically.  Standards like SUSv3 say to humor them, because they paid for the
standard...

http://www.ussg.iu.edu/hypermail/linux/kernel/0507.1/1065.html

> --Yigael

Rob
--
"One of my most productive days was throwing away 1000 lines of code."
  - Ken Thompson.

------=_Part_6853_18313260.1184176630691--