RE: Serial driver hangs

From: Paul Fulghum
Date: Fri Oct 01 2004 - 15:51:34 EST


On Fri, 2004-10-01 at 15:13, Stuart MacDonald wrote:
> I've come late to this discussion. Not sure what the scope of this
> cleanup is, but I'd like to see the flip buffers done away with
> entirely, to be replaced by a single buffer with proper r/w locking.
> Or keep the flip arrangement, but move it out of tty_struct so that it
> can be made larger. Some of our high speed products find the rx buffer
> to be less than sufficient.

This started as a bug report of a lockup under high load.
(2 ports @ 921600bps)

The cause was serial.c (kernel 2.4) not clearing
the receive IRQ if the flip buffer was full.
The ISR simply returned without flushing the
receive FIFO or disabling receive interrupts.
The short term cure for the lock up is to
flush the receive FIFO and discard the data.

The discussion then descended into analysis of the
flip buffer scheme in general. Everyone seems to agree
it should be eliminated or replaced.
It has synchronization problems for SMP.

Alan is busy reworking other tty locking
issues, and it probably annoyed by the noise
created by this thread :-)

I suspect when those issues are resovled there
will be an opportunity to submit suggestions and patches.

--
Paul Fulghum
paulkf@xxxxxxxxxxxxx

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