Re: PROBLEM: kernel oops with g_serial USB gadget on 2.6.30

From: David Brownell
Date: Tue Jun 23 2009 - 12:52:53 EST


On Tuesday 23 June 2009, Marek Szyprowski wrote:
> /* low_latency means ldiscs work in tasklet context, without
>  * needing a workqueue schedule ... easier to keep up.
>  */
>
> So in low latency mode calls are made from a tasklet.

... and that has, at some point since 2.6.26 or so, become a
problem that caused oopsing.


> This is not true in
> my case, as the S3C OTG UDC driver does all its job in interrupts. This
> way also a (usb) packet_done callback is done from an interrupt. I expect
> that g_serial driver interacts with tty layer in that packet_done callback,
> so this is the source of the problems. I noticed that some other UDC
> drivers also does all its job from an interrupt, so they also might be
> affected. How this bug should be properly resolved?

Change the u_serial.c code so that this newish tty behavior
stops causing problems: don't set low_latency.

But also try and sort through any consequences of that, and
don't forget to update the comments which talk about how the
low_latency setting is affecting code flow.

- Dave
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/