Pete Zaitcev wrote:
On Wed, 13 Feb 2008 13:31:54 -0600, Andrew McKay <[EMAIL PROTECTED]> wrote:
spin_lock_bh(&port->lock);
if (port->write_urb_busy) {
If you lock against callbacks and do not trigger tasklets yourself,
you must use spin_lock_irqsave (or spin_lock_irq if you are belong
to Oliver's denomination).
Hmm okay, I'll look into this.
Don't overthink it.
Look at the traffic with usbmon, it provides you timestamps for
(S)ubmission and (C)allback events.
I don't completely understand the USB subsystem, so this may be a dumb question.
Once the callback function has been called does this guarantee that the URB
has already been sent to hardware? Or does it mean it's been copied into
another buffer somewhere waiting to sent out of the host controller?
I'll definitely look into this usbmon app. I have timed things out and from the
time I call usb_submit_urb until the callback is 1 jiffie or less. So worst
case 20ms in my kernel. It can't be causing the variations in timing that I'm
seeing.
I did manage to fix my weird flashing rate by keeping the devnode open in
userland. It appears opening and closing the device was causing my issues. I'm
looking into that now.
Thanks,
Andrew
-
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html