mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH 1/5] console: add missing newline conversion for putc_ll
@ 2018-06-19  6:41 Sascha Hauer
  2018-06-19  6:41 ` [PATCH 2/5] console: remove duplicate newline conversion Sascha Hauer
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Sascha Hauer @ 2018-06-19  6:41 UTC (permalink / raw)
  To: Barebox List

putc_ll doesn't do newline conversion (and it shouldn't do, as it's
a static inline function for early debugging, adding more code there
is not nice), so add newline conversion to the console code when
it uses putc_ll for printing early messages.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
 common/console.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/common/console.c b/common/console.c
index ab3d4d397c..c40eba6d55 100644
--- a/common/console.c
+++ b/common/console.c
@@ -513,6 +513,8 @@ void console_putc(unsigned int ch, char c)
 
 	case CONSOLE_INITIALIZED_BUFFER:
 		kfifo_putc(console_output_fifo, c);
+		if (c == '\n')
+			putc_ll('\r');
 		putc_ll(c);
 		return;
 
-- 
2.17.1


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

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

end of thread, other threads:[~2018-06-19  6:41 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-06-19  6:41 [PATCH 1/5] console: add missing newline conversion for putc_ll Sascha Hauer
2018-06-19  6:41 ` [PATCH 2/5] console: remove duplicate newline conversion Sascha Hauer
2018-06-19  6:41 ` [PATCH 3/5] console_simple: Remove duplicated " Sascha Hauer
2018-06-19  6:41 ` [PATCH 4/5] console_simple: Fix " Sascha Hauer
2018-06-19  6:41 ` [PATCH 5/5] console_simple: add newline conversion for putc_ll case Sascha Hauer

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