On Tue, 2 Apr 2013, Oliver Neukum wrote:

> On Monday 01 April 2013 22:05:47 Mike Verstegen wrote:
> 
> Hi,
> 
> > Such a simple question you asked -- but it lead to a useful discovery.
> > 
> > My logs show that acm_tty_write is called multiple times
> > 
> > - The application opens the device and then calls write() to send the 4 
> > byte message to the fd. This results in a call to acm_tty_write
> > - From somewhere else, acm_tty_write is called several times, each with a 
> > count=1 and one of the offending characters noted above.
> > 
> > To get find out where the unexpected calls to acm_tty_write were coming 
> > from, I added a dump_stack at the entry point to acm_tty_write. From those 
> > stack frames, I can see that the first acm_tty_write call is from my 
> > application, but the second and subsequent calls are from  a kworker thread.
> 
> This is unexpected.
> 
> > So at this point, it doesn't look like a cdc_acm driver problem, but 
> > instead an unexpected call to acm_tty_write from another process. Having 
> > briefly looked the trace output of the kworker queue, it may a challenge to 
> > find out what thread in there is making this call.
> 
> I am afraid I have no idea on debugging for worker threads but people on LKML
> might know.

Mike, why don't you post one of the stack dumps for the kworker thread?

Alan Stern

--
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

Reply via email to