linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] serial.c 2.4.20 - ST16654 xmit data loss
@ 2003-06-03 22:45 Ed Vance
  0 siblings, 0 replies; only message in thread
From: Ed Vance @ 2003-06-03 22:45 UTC (permalink / raw)
  To: 'linux-kernel'; +Cc: 'linux-serial', 'Marcelo Tosatti'

Fixes transmit FIFO overrun that affects ST16654 UART only.
Bug found by William King [William.King@dadaboom.com]
Symptom: random loss of transmit data, worse at low baud rates.
Cause: on 16654 UART, default transmit FIFO trigger level is 8
       instead of zero, so full FIFO depth is not available 
       when transmit interrupt arrives. Race between UART 
       transmitting last 8 bytes still in TX FIFO and driver 
       writing full FIFO length of new data to TX FIFO.

diff -Naur -X dontdiff.txt linux-2.4.20/drivers/char/serial.c
patched-2.4.20/drivers/char/serial.c
--- linux-2.4.20/drivers/char/serial.c	Thu Nov 28 15:53:12 2002
+++ patched-2.4.20/drivers/char/serial.c	Tue May 27 15:14:58 2003
@@ -306,8 +306,8 @@
 	{ "TI16750", 64, UART_CLEAR_FIFO | UART_USE_FIFO},
 	{ "Startech", 1, 0},	/* usurped by cyclades.c */
 	{ "16C950/954", 128, UART_CLEAR_FIFO | UART_USE_FIFO},
-	{ "ST16654", 64, UART_CLEAR_FIFO | UART_USE_FIFO |
-		  UART_STARTECH }, 
+	{ "ST16654", 64-8, UART_CLEAR_FIFO | UART_USE_FIFO |
+		  UART_STARTECH },	/* ST16654 xmit trigger lvl = 8 */
 	{ "XR16850", 128, UART_CLEAR_FIFO | UART_USE_FIFO |
 		  UART_STARTECH },
 	{ "RSA", 2048, UART_CLEAR_FIFO | UART_USE_FIFO }, 

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2003-06-03 22:32 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-06-03 22:45 [PATCH] serial.c 2.4.20 - ST16654 xmit data loss Ed Vance

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).