Messages in this thread | | | Date | Mon, 20 Dec 2004 04:21:34 -0800 | From | Pete Zaitcev <> | Subject | Re: [linux-usb-devel] Re: My vision of usbmon |
| |
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/
| |