In message: <200902012031.56899.hsela...@c2i.net>
            Hans Petter Selasky <hsela...@c2i.net> writes:
: On Sunday 01 February 2009, Andrew Thompson wrote:
: > On Sun, Feb 01, 2009 at 08:01:05PM +0100, Hans Petter Selasky wrote:
: > > Hi Andrew,
: > >
: > > Regarding using taskqueues.
: > >
: > > Yes - USB2 can use taskqueues, but I would very much like to have the
: > > original queueing mechanism intact.
: >
: > Can you explain this further? What is t0 vs t1?
: >
: > A taskqueue will execute tasks sequentially, 
: 
: Hi Andrew,
: 
: I've looked in the taskqueue code:
: 
:         if (task->ta_pending) {
:                 task->ta_pending++;
:                 TQ_UNLOCK(queue);
:                 return 0;
:         }
: 
: Take the following for example. Now you changed it a little bit, but I see 
: similar issues where other commands are involved:
: 
: 1) queue DTR on cmd
: 2) queue DTR off cmd
: 3) queue DTR on cmd

This is a bad example.  In this case, clearly you'd want to turn it
on, wait for it to go on, wait a while, turn it off, wait for it to go
off, wait a while, then repeat the on part.  If you are trying to get
a notch signal in DTR, you have to cope this way.  If you are
implementing an ioctl from userland to do this (as exposed by the tty
system), then you'd need to wait for the DTR command to finish anyway
before returning to userland, no?

There's likely other reasons for wanting to do this, but DTR changes
should be synchronous to the caller.

Warner
_______________________________________________
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"

Reply via email to