lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-id: <200705161919.21304.yinghai.lu@sun.com>
Date:	Wed, 16 May 2007 19:19:20 -0700
From:	Yinghai Lu <Yinghai.Lu@....COM>
To:	Andi Kleen <ak@...e.de>, Andrew Morton <akpm@...ux-foundation.org>,
	rmk@....linux.org.uk
Cc:	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	Yinghai.Lu@....COM
Subject: [PATCH]x86_64: early_print kernel console should send CRLF not LFCR

[PATCH]x86_64: early_print kernel console should send CRLF not LFCR

   in 
	commit d358788f3f30113e49882187d794832905e42592
	Author: Russell King <rmk@...-67.arm.linux.org.uk>
	Date:   Mon Mar 20 20:00:09 2006 +0000

    Glen Turner reported that writing LFCR rather than the more
    traditional CRLF causes issues with some terminals.

    Since this aflicts many serial drivers, extract the common code
    to a library function (uart_console_write) and arrange for each
    driver to supply a "putchar" function.

    but early_printk is left out. 

    Signed-off-by: Yinghai Lu <yinghai.lu@....com>
    Cc: Andi Kleen <ak@...e.de>
    Cc: Russell King <rmk@....linux.org.uk>

diff --git a/arch/x86_64/kernel/early_printk.c b/arch/x86_64/kernel/early_printk.c
index 56eaa25..296d2b0 100644
--- a/arch/x86_64/kernel/early_printk.c
+++ b/arch/x86_64/kernel/early_printk.c
@@ -91,9 +91,9 @@ static int early_serial_putc(unsigned char ch)
 static void early_serial_write(struct console *con, const char *s, unsigned n)
 {
 	while (*s && n-- > 0) {
-		early_serial_putc(*s);
 		if (*s == '\n')
 			early_serial_putc('\r');
+		early_serial_putc(*s);
 		s++;
 	}
 }
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ