IMX6Q Rx Fifo Overrun

Hi,

We have an application that use an UART port to communicate and receive information from other device using RS232. Basically, this application sends a query and the device sends a response to it, which is a stream of bytes. The maximum response size is around to 520 bytes. Today, we have done several tests with our recently acquired Apalis IMX6Q (Quad 2GB IT - V1.1A )+ Ixora base board and have experimented the following error using IMX6 uarts:

Testing with ttymxc1 (output from dmesg):

[ 3435.751632] imx-uart 21e8000.serial: Rx FIFO overrun
[ 3435.757846] imx-uart 21e8000.serial: Rx FIFO overrun
[ 3435.764065] imx-uart 21e8000.serial: Rx FIFO overrun
[ 3435.770457] imx-uart 21e8000.serial: Rx FIFO overrun

Testing with ttymxc3 (output from dmesg):

[ 3581.644085] imx-uart 21f0000.serial: Rx FIFO overrun
[ 3581.650222] imx-uart 21f0000.serial: Rx FIFO overrun
[ 3581.656402] imx-uart 21f0000.serial: Rx FIFO overrun
[ 3581.662539] imx-uart 21f0000.serial: Rx FIFO overrun

This is only a portion of dmesg log, there were much more.

When this error appeared, we have had bad transferences. For these test, we have configured both ttymxc1 and ttymxc3 to work at 230400 in raw mode and our application uses termios API to configure the UART device.

We have run these tests using a 3.14.52 standard kernel (that one built in with BSP Linux tar.gz) with a Debian 8 rootfs. Also we have done the same tests using 3.14.28 RT Patched kernel (using 3.14.28 base kernel to compile from toradex git branch). In both situations, we have experimented the error.

I have searched in serial imx linux driver that error. It is printed in line 792 (drivers/tty/serial/imx.c):

.....   
        sts2 = readl(sport->port.membase + USR2);
        if (sts2 & USR2_ORE) {
                dev_err(sport->port.dev, "Rx FIFO overrun\n");
                sport->port.icount.overrun++;
                writel(sts2 | USR2_ORE, sport->port.membase + USR2);
        }
.....

I would like to know if it is a driver problem. How can we solve it?

Please, we would really appreciate any help or advice. Using UART device is mandatory for us. Please let me know if you need any other information.

Thanks in advance.

Hi,

I have found a solution backporting the imx serial driver from mainline kernel 3.18.31 (drivers/tty/serial/imx.c from kernel.org). I have replaced imx.c from toradex imx6 3.14.28 kernel, recompile it and the Rx Fifo Overrun error is seemed to be solved, such as I have not observed it again in syslog doing some tests.

Thanks.