linux-serial.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [RFC PATCH] serial: omap: only inform once about missing wakeirq support
@ 2014-02-13  9:25 Uwe Kleine-König
  2014-02-13  9:47 ` Markus Pargmann
  0 siblings, 1 reply; 3+ messages in thread
From: Uwe Kleine-König @ 2014-02-13  9:25 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Tony Lindgren, linux-serial
  Cc: kernel, Roger Quadros, Felipe Balbi, Linus Walleij, Kevin Hilman

The unconditional output in serial_omap_startup clutters dmesg quite a
bit when booting with systemd because the console device is opened
repeatedly.

Without this patch, directly after boot + login I get:

	# dmesg | grep -c 'omap_uart 48024000.serial: no wakeirq for uart2'
	79

This was introduced in commit 2a0b965cfb6e (serial: omap: Add support
for optional wake-up) which was applied for v3.13-rc1.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
---
Hello,

actually this change is not optimal because it would be nicer to report
once per device instead of not once per driver. But adding a variable to
driver data just for that seems overkill, too. Maybe downgrading the
message to dev_dbg is fine, too?

What do you think?

Best regards
Uwe

 drivers/tty/serial/omap-serial.c | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/drivers/tty/serial/omap-serial.c b/drivers/tty/serial/omap-serial.c
index 2116e76b9559..bbcd95360553 100644
--- a/drivers/tty/serial/omap-serial.c
+++ b/drivers/tty/serial/omap-serial.c
@@ -739,8 +739,13 @@ static int serial_omap_startup(struct uart_port *port)
 		}
 		disable_irq(up->wakeirq);
 	} else {
-		dev_info(up->port.dev, "no wakeirq for uart%d\n",
-			 up->port.line);
+		static int once = 1;
+
+		if (once) {
+			dev_info(up->port.dev, "no wakeirq for uart%d\n",
+				 up->port.line);
+			once = 0;
+		}
 	}
 
 	dev_dbg(up->port.dev, "serial_omap_startup+%d\n", up->port.line);
-- 
1.8.5.3

--
To unsubscribe from this list: send the line "unsubscribe linux-serial" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

end of thread, other threads:[~2014-02-13  9:57 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-02-13  9:25 [RFC PATCH] serial: omap: only inform once about missing wakeirq support Uwe Kleine-König
2014-02-13  9:47 ` Markus Pargmann
2014-02-13  9:57   ` Uwe Kleine-König

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