On Sun, May 07, 2006 at 03:27:33PM +0200, Michael Buesch wrote: > On Sunday 07 May 2006 15:16, you wrote: > > On Sunday 07 May 2006 15:03, you wrote: > > > This does not handle the case of partial read correctly - the code > > > should be > > > > > > return ret ? : -ERESTARTSYS; > > Or, hm. Shouldn't we > return ret ? : err; > > err is -EINTR -ERESTARTSYS is the proper return code for this case - the signal handling code will either convert it to EINTR for userspace, or restart the system call after handling the signal, depending on the state of the SA_RESTART flag set by sigaction().
Attachment:
pgpETZKeWjVUy.pgp
Description: PGP signature
- Follow-Ups:
- Re: [patch 2/6] New Generic HW RNG
- From: Michael Buesch <[email protected]>
- Re: [patch 2/6] New Generic HW RNG
- References:
- [patch 0/6] New Generic HW RNG
- From: Michael Buesch <[email protected]>
- Re: [patch 2/6] New Generic HW RNG
- From: Sergey Vlasov <[email protected]>
- Re: [patch 2/6] New Generic HW RNG
- From: Michael Buesch <[email protected]>
- Re: [patch 2/6] New Generic HW RNG
- From: Michael Buesch <[email protected]>
- [patch 0/6] New Generic HW RNG
- Prev by Date: Re: sched_clock() uses are broken
- Next by Date: Re: [patch 2/6] New Generic HW RNG
- Previous by thread: Re: [patch 2/6] New Generic HW RNG
- Next by thread: Re: [patch 2/6] New Generic HW RNG
- Index(es):