----- Original Message -----
From: Martin Diehl <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, May 01, 2001 2:01 AM
Subject: Re: [linux-usb-devel] Queued / linked bulk urb's to
differentendpoints


> On the other hand, there are a lot of usb-drivers with tons of races in
> the conditional schedule patch. I'm going to write a comment on this
> tomorrow. The basic message is there is a window between testing
> urb->status==-EINPROGRESS and going to sleep during which a wake_up()
> from the completion-handler (interrupt-context!) is simply lost.
> That's why using sleep_on() and friends is now deprecated!
> Instead one should use set_current_state() and schedule() in combination
> with a private waitqueue - look into drivers/usb/audio.c for example.
>
> Martin
>

Wouldn't it work if I clear the interrupt flag using cli() before testing
the urb->status? sleep_on() and interruptible_sleep_on() set the flag again
when they start waiting. So interrupts should not get lost. Or is it a
mistake?


_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
http://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to