Am Mittwoch 07 April 2010 18:10:49 schrieb Alan Stern: > On Wed, 7 Apr 2010, Hendrik Sattler wrote: > > I am currently trying a setup of using dummy_hcd with f_obex and get get > > freezes each time. > > Here's what I do (linux-2.6.33): > > $ modprobe dummy_hcd > > $ modprobe g_serial use_acm=0 use_obex_1 n_ports=1 > > > > I then attach a local version of obexpushd (I'm the author) to > > /dev/ttyGS0 and when looking for it, I get: > > Found 1 usb devices. > > Device 0: > > Manufacturer: Linux 2.6.33 with dummy_udc > > Product: Gadget Serial v2.4 > > Serial: (null) > > Description: CDC Object Exchange (OBEX) > > > > However, when trying to transfer anything with obexftp (e.g. something > > simple like a directory listing), I immediately get a hard lock-up. > > > > When doing the same thing with a connected SE K800i, it works just fine. > > > > Any ideas? > > I have never tried using dummy-hcd with g-serial. It's possible that > either g_serial or the host-side driver makes assumptions that are > usually correct for normal controllers but aren't correct for > dummy-hcd, although I can't think of any examples offhand. > > What happens if you don't use obex? For instance, if you simply attach > a minicom session to each end of the emulated serial connection? It was a problem with my obex server application. However, that should never cause a total freeze. Running through valgrind somehow made it survive the bug. I wrong pointer was given to the write() call, probably with invalid memory. A quick lock at gs_write() in u_serial.c didn't show any checks that the buffer pointer is valid. Is this already done by the tty layer itself? HS -- 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