Pete Zaitcev wrote:
Al Borchers did explain why sending X-OFF in the driver was
appropriate once upon a time.

I don't remember talking about this and couldn't find it in a quick google--can you point me to it?

but perhaps you would wish to preserve that technique after you
examined his message in the list archives. In such case, it ought
to be easy to create a little queue in io_ti.c.

The problem is not with sending XOFF, but with dropping/asserting RTS. So I don't think a queue is needed.

The problem that Sam found is that throttle can be called in interrupts,
and io_ti throttle calls usb_control_msg to drop RTS, but that sleeps.

However, it is simply not necessary for io_ti throttle to explicitly
drop RTS.  The firmware in the TI based edgeports is capable
of handling incoming flow control.  All that is needed is for the
driver to stop submitting urbs on the bulk in endpoint for the port
when throttle is called, and restart submitting urbs when unthrottle
is called.  The device will drop RTS when the bulk in urbs stop, and
assert RTS when the urbs start again.

The io_ti.c in the kernel uses this feature _and_ also explicitly controls
RTS for hardware flow control.  Greg might remember why this was done--this
is the way the code was when I started working on it.

The way I fixed this was to not explicitly drop RTS in throttle
but simply stop submitting the urbs.  You can see what I did in
www.brimson.com/downloads/drivers/edgeport-0.4-3.tgz.  As soon as
I finish and submit the 2.6 version of io_ti.c, I will submit a 2.4
version with these changes.

Another potential problem is that usbserial throttle can also sleep
when it calls down().  You will have to fix that some other way.

-- Al





-------------------------------------------------------
This SF.Net email is sponsored by: YOU BE THE JUDGE. Be one of 170
Project Admins to receive an Apple iPod Mini FREE for your judgement on
who ports your project to Linux PPC the best. Sponsored by IBM.
Deadline: Sept. 24. Go here: http://sf.net/ppc_contest.php
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to