lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 20 Mar 2014 23:34:11 +0000
From:	"Bollinger, Seth" <Seth.Bollinger@...i.com>
To:	Peter Hurley <peter@...leysoftware.com>
CC:	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	linux-serial <linux-serial@...r.kernel.org>
Subject: Re: Possible software flow problem in serial_core


>What hardware is this?

We¹re using the Freescale mxs-auart driver (i.mx28).
 
>A 16550 transmitter doesn't shut-off at uart->stop_tx(), so the remaining
>data in the transmitter FIFO is still transmitted.

Ok, I just reviewed the 8250 driver and you¹re correct, it appears the
transmitter is only disabled on the 16C950.  I misread before (incorrectly
saw 16C550)...

>Some hardware has (relatively) big FIFOs and allows the transmitter to be
>shutoff, but these should unconditionally re-enable the transmitter
>without
>clearing the xmit fifo.

Do you have a driver that would be a good example of this?  From looking
at serial_core.c:uart_start(), is seems that start_tx() is only called if
the serial_core ring buffer is not empty.  If we don¹t stop the
transmitter, we slew too many characters.

>Are you seeing lost data? Maybe it's because soft flow-control is to
>slow to shutoff the sender?

No dropped bytes, but we do see a few bytes trapped in the fifo because we
received an XOFF.  When we receive the XON, start_tx() is never called
because the serial_core ring buffer is empty, and we have no more data to
transmit.  When we enable the transmitter manually, these bytes will pop
out.

Thanks for all of your help!

Seth

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

Powered by blists - more mailing lists