Date: Tue, 21 Oct 1997 03:50:28 +0100 (MET) From: Luigi Rizzo <luigi@labinfo.iet.unipi.it> To: hackers@freebsd.org Subject: How to deal with ERESTART ? Message-ID: <199710210250.DAA20149@labinfo.iet.unipi.it>
next in thread | raw e-mail | index | archive | help
I am having a problem in dealing with ERESTART in the audio driver. Right now I have a sequence like res = tsleep(..., PRIBIO | PCATCH , ..., timeout ) if (res == EINTR || res = ERESTART) ... do the same thing, typically abort operations. the aim was to make it easy for apps to gain control on the driver. Catching ERESTART this way had some interesting side effects on some applications which makes me thing that it is probably wrong to assimilate ERESTART and EINTR ? So my question is: when can i get ERESTART as a result from tsleep(), and would it be better to just restart the tsleep in this case ? Cheers Luigi -----------------------------+-------------------------------------- Luigi Rizzo | Dip. di Ingegneria dell'Informazione email: luigi@iet.unipi.it | Universita' di Pisa tel: +39-50-568533 | via Diotisalvi 2, 56126 PISA (Italy) fax: +39-50-568522 | http://www.iet.unipi.it/~luigi/ _____________________________|______________________________________
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199710210250.DAA20149>