Commit 2a14b80c authored by Nicolas Pitre's avatar Nicolas Pitre Committed by Russell King

ARM: 8717/2: debug printch/printascii: translate '\n' to "\r\n" not "\n\r"

Some terminals apparently have issues with "\n\r" and mess up the
display. Let's use the traditional "\r\n" ordering.
Signed-off-by: default avatarNicolas Pitre <nico@linaro.org>
Reported-by: default avatarChris Brandt <Chris.Brandt@renesas.com>
Tested-by: default avatarChris Brandt <Chris.Brandt@renesas.com>
Signed-off-by: default avatarRussell King <rmk+kernel@armlinux.org.uk>
parent de880632
...@@ -85,25 +85,28 @@ hexbuf_rel: .long hexbuf_addr - . ...@@ -85,25 +85,28 @@ hexbuf_rel: .long hexbuf_addr - .
ENTRY(printascii) ENTRY(printascii)
addruart_current r3, r1, r2 addruart_current r3, r1, r2
b 2f 1: teq r0, #0
1: waituart r2, r3
senduart r1, r3
busyuart r2, r3
teq r1, #'\n'
moveq r1, #'\r'
beq 1b
2: teq r0, #0
ldrneb r1, [r0], #1 ldrneb r1, [r0], #1
teqne r1, #0 teqne r1, #0
bne 1b reteq lr
ret lr 2: teq r1, #'\n'
bne 3f
mov r1, #'\r'
waituart r2, r3
senduart r1, r3
busyuart r2, r3
mov r1, #'\n'
3: waituart r2, r3
senduart r1, r3
busyuart r2, r3
b 1b
ENDPROC(printascii) ENDPROC(printascii)
ENTRY(printch) ENTRY(printch)
addruart_current r3, r1, r2 addruart_current r3, r1, r2
mov r1, r0 mov r1, r0
mov r0, #0 mov r0, #0
b 1b b 2b
ENDPROC(printch) ENDPROC(printch)
#ifdef CONFIG_MMU #ifdef CONFIG_MMU
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment