![]() | |||||||||||
Messages in this thread |
On Mon, 20 Dec 2004 12:55:59 +0100, Oliver Neukum <oliver@neukum.org> wrote:
> Am Montag, 20. Dezember 2004 08:04 schrieb Pete Zaitcev:
> > + add_wait_queue(&rp->wait, &waita);
> > + while ((ep = mon_text_fetch(rp, mbus)) == NULL) {
> > + if (file->f_flags & O_NONBLOCK) {
> > + remove_wait_queue(&rp->wait, &waita);
> > + return -EWOULDBLOCK; /* Same as EAGAIN in Linux */
> > + }
> > + /*
> > + * We do not count nwaiters, because ->release is supposed
> > + * to be called when all openers are gone only.
> > + */
> > + set_current_state(TASK_INTERRUPTIBLE);
>
> Here you can lose a wakeup.
>
> > + schedule();
Thanks, Oliver. Indeed, it's a bug.
-- Pete
-
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: 2005-03-22 14:08 [from the cache] ©2003-2008 | |||||||||||