linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] mxs-auart: count FIFO overrun errors
@ 2016-11-16 11:37 Wolfgang Ocker
  2016-11-16 11:47 ` Fabio Estevam
  0 siblings, 1 reply; 2+ messages in thread
From: Wolfgang Ocker @ 2016-11-16 11:37 UTC (permalink / raw)
  To: linux-arm-kernel, linux-kernel
  Cc: Greg Kroah-Hartman, Jiri Slaby, Wolfgang Ocker

The mxs-auart driver does not count FIFO overrun errors. These errors never
appear in /proc/tty/driver/ttyAPP. This is because the OERR status bit is
masked by read_status_mask in the rx interrupt function, but the
AUART_STAT_OERR bit is never set in read_status_mask. The patch enables the
counting of overrun errors.

Signed-off-by: Wolfgang Ocker <weo@reccoware.de>
---
 v2: sent with git-send-email. Evolution changes a leading space to 0xa0 :(

 drivers/tty/serial/mxs-auart.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/tty/serial/mxs-auart.c b/drivers/tty/serial/mxs-auart.c
index 770454e0dfa3..8c1c9112b3fd 100644
--- a/drivers/tty/serial/mxs-auart.c
+++ b/drivers/tty/serial/mxs-auart.c
@@ -1016,7 +1016,7 @@ static void mxs_auart_settermios(struct uart_port *u,
 			ctrl |= AUART_LINECTRL_EPS;
 	}
 
-	u->read_status_mask = 0;
+	u->read_status_mask = AUART_STAT_OERR;
 
 	if (termios->c_iflag & INPCK)
 		u->read_status_mask |= AUART_STAT_PERR;
-- 
2.10.0

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH v2] mxs-auart: count FIFO overrun errors
  2016-11-16 11:37 [PATCH v2] mxs-auart: count FIFO overrun errors Wolfgang Ocker
@ 2016-11-16 11:47 ` Fabio Estevam
  0 siblings, 0 replies; 2+ messages in thread
From: Fabio Estevam @ 2016-11-16 11:47 UTC (permalink / raw)
  To: Wolfgang Ocker
  Cc: linux-arm-kernel, linux-kernel, Greg Kroah-Hartman, Jiri Slaby

On Wed, Nov 16, 2016 at 9:37 AM, Wolfgang Ocker <weo@reccoware.de> wrote:
> The mxs-auart driver does not count FIFO overrun errors. These errors never
> appear in /proc/tty/driver/ttyAPP. This is because the OERR status bit is
> masked by read_status_mask in the rx interrupt function, but the
> AUART_STAT_OERR bit is never set in read_status_mask. The patch enables the
> counting of overrun errors.
>
> Signed-off-by: Wolfgang Ocker <weo@reccoware.de>

Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-11-16 11:47 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-11-16 11:37 [PATCH v2] mxs-auart: count FIFO overrun errors Wolfgang Ocker
2016-11-16 11:47 ` Fabio Estevam

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).