public inbox for linux-serial@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] serial: sh-sci: Remove BREAK/FRAME/PARITY/OVERRUN printouts
@ 2021-12-07  2:02 Magnus Damm
  2021-12-07  7:52 ` Geert Uytterhoeven
  2021-12-07  8:25 ` Wolfram Sang
  0 siblings, 2 replies; 3+ messages in thread
From: Magnus Damm @ 2021-12-07  2:02 UTC (permalink / raw)
  To: linux-serial
  Cc: Magnus Damm, geert+renesas, gregkh, linux-renesas-soc,
	wsa+renesas, jirislaby

From: Magnus Damm <damm+renesas@opensource.se>

Update the SCIF serial driver to remove printouts for break, frame, parity
and overrun errors. This reduces the amount of console printouts generated
by the defconfig kernel on R-Car Gen3 for certain use cases. To retrieve
more information about such errors the user may inspect counters. Also these
errors are fed into the TTY layer for further application specific handling.

Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
---

 Applies to v5.16-rc4

 Previous version sent as:
 [PATCH] serial: sh-sci: Use dev_dbg() for frame and parity errors

 drivers/tty/serial/sh-sci.c |   12 ------------
 1 file changed, 12 deletions(-)

--- 0001/drivers/tty/serial/sh-sci.c
+++ work/drivers/tty/serial/sh-sci.c	2021-12-07 10:37:45.974123374 +0900
@@ -895,11 +895,9 @@ static void sci_receive_chars(struct uar
 				if (status & SCxSR_FER(port)) {
 					flag = TTY_FRAME;
 					port->icount.frame++;
-					dev_notice(port->dev, "frame error\n");
 				} else if (status & SCxSR_PER(port)) {
 					flag = TTY_PARITY;
 					port->icount.parity++;
-					dev_notice(port->dev, "parity error\n");
 				} else
 					flag = TTY_NORMAL;
 
@@ -939,8 +937,6 @@ static int sci_handle_errors(struct uart
 		/* overrun error */
 		if (tty_insert_flip_char(tport, 0, TTY_OVERRUN))
 			copied++;
-
-		dev_notice(port->dev, "overrun error\n");
 	}
 
 	if (status & SCxSR_FER(port)) {
@@ -949,8 +945,6 @@ static int sci_handle_errors(struct uart
 
 		if (tty_insert_flip_char(tport, 0, TTY_FRAME))
 			copied++;
-
-		dev_notice(port->dev, "frame error\n");
 	}
 
 	if (status & SCxSR_PER(port)) {
@@ -959,8 +953,6 @@ static int sci_handle_errors(struct uart
 
 		if (tty_insert_flip_char(tport, 0, TTY_PARITY))
 			copied++;
-
-		dev_notice(port->dev, "parity error\n");
 	}
 
 	if (copied)
@@ -990,8 +982,6 @@ static int sci_handle_fifo_overrun(struc
 
 		tty_insert_flip_char(tport, 0, TTY_OVERRUN);
 		tty_flip_buffer_push(tport);
-
-		dev_dbg(port->dev, "overrun error\n");
 		copied++;
 	}
 
@@ -1013,8 +1003,6 @@ static int sci_handle_breaks(struct uart
 		/* Notify of BREAK */
 		if (tty_insert_flip_char(tport, 0, TTY_BREAK))
 			copied++;
-
-		dev_dbg(port->dev, "BREAK detected\n");
 	}
 
 	if (copied)

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

end of thread, other threads:[~2021-12-07  8:25 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-12-07  2:02 [PATCH] serial: sh-sci: Remove BREAK/FRAME/PARITY/OVERRUN printouts Magnus Damm
2021-12-07  7:52 ` Geert Uytterhoeven
2021-12-07  8:25 ` Wolfram Sang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox