This patch changes the RX interrupt threshold on UART 0 for the GTA01 from 8 characters to 4 characters. This provides 4 additional character times for the interrupt to be acted upon before a buffer overrun occurs.

(This is insufficient to solve the buffer overrun problem on the GTA01, but there is no significant cost to interrupt earlier and some small gain to be had.)

This patch is _not_ suitable for upstream.

Signed-off-by: Mike Westerhof <[EMAIL PROTECTED]>
---
--- git/arch/arm/mach-s3c2410/mach-gta01.old 2008-05-11 12:27:58.000000000 -0500
+++ git/arch/arm/mach-s3c2410/mach-gta01.c   2008-05-11 12:50:58.000000000 -0500
@@ -87,6 +87,8 @@ static struct map_desc gta01_iodesc[] __
 #define UCON S3C2410_UCON_DEFAULT
 #define ULCON S3C2410_LCON_CS8 | S3C2410_LCON_PNONE | S3C2410_LCON_STOPB
 #define UFCON S3C2410_UFCON_RXTRIG8 | S3C2410_UFCON_FIFOMODE
+/* UFCON for the gta01 port 0 sets the FIFO trigger level at 4, not 8 */
+#define UFCON_GTA01_PORT0 S3C2410_UFCON_FIFOMODE

 static struct s3c2410_uartcfg gta01_uartcfgs[] = {
        [0] = {
@@ -94,7 +96,7 @@ static struct s3c2410_uartcfg gta01_uart
                .flags       = 0,
                .ucon        = UCON,
                .ulcon       = ULCON,
-               .ufcon       = UFCON,
+               .ufcon       = UFCON_GTA01_PORT0,
        },
        [1] = {
                .hwport      = 1,

Reply via email to