MLK-11258 tty: serial: imx: disable overrun interrupt during uart port shutdown
authorFugang Duan <b38611@freescale.com>
Fri, 17 Jul 2015 03:43:31 +0000 (11:43 +0800)
committerNitin Garg <nitin.garg@nxp.com>
Mon, 19 Mar 2018 19:47:28 +0000 (14:47 -0500)
Also disable rx fifo overrun interrupt during uart port shutdown.

Signed-off-by: Fugang Duan <B38611@freescale.com>
(cherry picked from commit: 39eb703f6c9f9359723f3fa22e798b1d21b44c67)

drivers/tty/serial/imx.c

index 918bc56..936240b 100644 (file)
@@ -406,12 +406,14 @@ static void imx_stop_rx(struct uart_port *port)
                }
        }
 
-       temp = readl(sport->port.membase + UCR2);
-       writel(temp & ~UCR2_RXEN, sport->port.membase + UCR2);
-
-       /* disable the `Receiver Ready Interrrupt` */
+       /* disable the Receiver Ready and overrun Interrrupt */
        temp = readl(sport->port.membase + UCR1);
        writel(temp & ~UCR1_RRDYEN, sport->port.membase + UCR1);
+       temp = readl(sport->port.membase + UCR4);
+       writel(temp & ~UCR4_OREN, sport->port.membase + UCR4);
+
+       temp = readl(sport->port.membase + UCR2);
+       writel(temp & ~UCR2_RXEN, sport->port.membase + UCR2);
 }
 
 /*