All of lore.kernel.org
 help / color / mirror / Atom feed
* Can EINTR be handled the way BSD handles it? -- a plea from a user-land  programmer...
@ 2000-11-03 19:29 george
  2000-11-03 19:41 ` Ulrich Drepper
  2000-11-03 20:20 ` Richard B. Johnson
  0 siblings, 2 replies; 15+ messages in thread
From: george @ 2000-11-03 19:29 UTC (permalink / raw)
  To: linux-kernel

Considering that the threading library for Linux uses signals to make it
work, would it be possible to change the Linux kernel to operate the way
BSD does--instead of returning EINTR, just restart the interrupted
primitive?

For example, if I'm using read(2) to read data from a file descriptor,
and a signal happens, the signal handler runs, and read(2) returns EINTR
after the system call finishes.  Then I'm supposed to catch this and
re-try the system call.

I assume that this is true for _any_ system call which makes the process
block, right?

Can we _PLEASE_PLEASE_PLEASE_ not do this anymore and have the kernel do
what BSD does:  re-start the interrupted call?

Please?  If this is something that would be acceptable for integration
into a mainline kernel, I would do my best to help with a patch.

If I'm wrong about this, please enlighten me.  Also, please cc: me off
the list, as I don't get the list directly.

Thank you for your consideration.
--
George T. Talbot
<george at moberg dot com>
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

^ permalink raw reply	[flat|nested] 15+ messages in thread
* Re: Can EINTR be handled the way BSD handles it? -- a plea from a user-land programmer...
@ 2000-11-04  3:06 David Feuer
  0 siblings, 0 replies; 15+ messages in thread
From: David Feuer @ 2000-11-04  3:06 UTC (permalink / raw)
  To: linux-kernel

I seem to recall when reading about sigaction in APUE, that while sigaction 
solves many of the races that can come up with various "signal" 
implementations, there were still some cases where there was no way to do 
what was desired without races.  Is there ANY way (in theory, at least) to 
create a race-free signalling system?

--
This message has been brought to you by the letter alpha and the number pi.
David Feuer
David_Feuer@brown.edu

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

^ permalink raw reply	[flat|nested] 15+ messages in thread
[parent not found: <20001105042410.C3961@fuji.laendle>]

end of thread, other threads:[~2000-11-07 15:55 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2000-11-03 19:29 Can EINTR be handled the way BSD handles it? -- a plea from a user-land programmer george
2000-11-03 19:41 ` Ulrich Drepper
2000-11-03 19:49   ` george
2000-11-03 21:34     ` dean gaudet
2000-11-03 19:51   ` kuznet
2000-11-03 21:24     ` H. Peter Anvin
2000-11-03 20:20 ` Richard B. Johnson
  -- strict thread matches above, loose matches on Subject: below --
2000-11-04  3:06 David Feuer
     [not found] <20001105042410.C3961@fuji.laendle>
2000-11-06 14:13 ` George Talbot
2000-11-06 16:55   ` Theodore Y. Ts'o
2000-11-06 18:50     ` Ulrich Drepper
2000-11-06 19:11       ` Ulrich Drepper
2000-11-06 19:37         ` kuznet
2000-11-07 15:53       ` Theodore Y. Ts'o
2000-11-07  4:46   ` dean gaudet

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.