lkml.org 
[lkml]   [2006]   [Jul]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Re: Strange Linux behaviour with blocking syscalls and stop signals+SIGCONT
Von: Ulrich Drepper <drepper@redhat.com>

> Manfred Spraul wrote:
> > 1) I would go further and try ERESTARTSYS: ERESTARTSYS means that the
> > kernel signal handler honors SA_RESTART
> > 2) At least for the futex functions, it won't be as easy as replacing
> > EINTR wiht ERESTARTSYS: the futex functions receive a timeout a the
> > parameter, with the duration of the wait call as a parameter. You must
> > use ERESTART_RESTARTBLOCK.
>
> Whoa, not so fast. At least the futex syscall but be interruptible by
> signals. It is crucial to return EINTR.

When you say "return" do you mean "in kernel", or "return
to userspace"? My (possibly naive) understanding is that
one could simply s/EINTR/ERESTARTNOHAND/ for FUTEX_WAIT, in
order to achieve the change I want: for userland that
ERESTARTNOHAND would be returned as EINTR if a signal
handler interrupted the FUTEX_WAIT.

Cheers,

Michael
--


"Feel free" – 10 GB Mailbox, 100 FreeSMS/Monat ...
Jetzt GMX TopMail testen: http://www.gmx.net/de/go/topmail
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2006-07-07 06:35    [W:0.185 / U:0.048 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site