Re: Blackberry regression

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Feb 26, 2009 at 08:52:09PM -0500, Paul O'Keefe wrote:
> I was generous and gave the device 100,000 micro seconds to settle. And
> boom (using your word!) all was well. It runs btool correctly, it syncs
> correctly and it's happy. And that's a solution that should be generic
> across the universe of devices we have to play with. I'll send Chris a
> patch based on his latest version and we can move forward from there.

I was finally able to reproduce the original timeout bug using a VM
containing Debian Lenny.

There were two issues confusing the debugging process.  One was that the
timeout appeared to be 1ms in gdb, but this was just a stack anomaly...
stepping a bit farther changed gdb's results... probably due to using
-O2 for the build.

The other issue was a timeout in libusb's usb_bulk_read() function.
This depended on:

	- a fairly modern tool chain (e.g. Debian Lenny or Ubuntu Jaunty)
	- a 2.6.28 kernel or higher (2.6.27 never shows this issue)

My setup is a Debian Etch system running 2.6.28.7, and a Debian Lenny
system running in a QEMU VM.  btool (compiled with g++ 4.1.2 on Etch)
runs fine on 2.6.28.7 and 2.6.28.4 on the bare Etch system.  But if I run
btool in the VM Lenny system using 2.6.28.4, compiled with g++ 4.3.2,
I get a timeout.  Adding a delay doesn't seem to help.

All kernels I'm using for testing, on both systems, are compiled on the
Etch system with gcc-3.3.

I've been slowly running through a git bisect of the kernel to try to
narrow this down.  I have to be careful, since there was another USB
bug that was fixed in 2.6.28.2 with commit:
73cb49b8860d9336ee4b24ecbc0d2358aff862f7

So far it's down to about 36 commits:

	good: eef70b217a7ab46e8e0cf75982ad75d8305d5591
	bad:  0bc77ecbe4f69ff8ead1d2abfe84ca9ba2a7bca4

The bad commit fails twice.

	1) compiled as-is, it gives 
		error in usb_bulk_write(): -2 error submitting URB:
		No such file or directory

	2) when the 2.6.28.2 patch is applied, it gives the timeout
		in usb_bulk_read()

Sorry it's not narrowed down further... I ran out of time tonight.

Thanks for any help you can provide.

- Chris

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux