diff options
author | Daniel Hellstrom <daniel@gaisler.com> | 2014-06-18 13:52:07 +0200 |
---|---|---|
committer | Daniel Hellstrom <daniel@gaisler.com> | 2014-06-26 10:25:25 +0200 |
commit | a0b976cdfc189333f1258244997caa8189669527 (patch) | |
tree | ed33c5b864c0201811fb844de87ef97886d90b26 | |
parent | 313c3ca2cbde5ac312816f2b9babbae2234195a3 (diff) |
LEON3: console print \r\n instead of \n\r
-rw-r--r-- | c/src/lib/libbsp/sparc/leon3/console/printk_support.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/c/src/lib/libbsp/sparc/leon3/console/printk_support.c b/c/src/lib/libbsp/sparc/leon3/console/printk_support.c index 35fb4b52e5..082e9a530e 100644 --- a/c/src/lib/libbsp/sparc/leon3/console/printk_support.c +++ b/c/src/lib/libbsp/sparc/leon3/console/printk_support.c @@ -94,12 +94,12 @@ send: __asm__ volatile ("nop"::); __asm__ volatile ("nop"::); __asm__ volatile ("nop"::); __asm__ volatile ("nop"::); } - regs->data = (unsigned int) ch; - if ((ch == '\n') && do_cr_on_newline) { - ch = '\r'; + regs->data = (unsigned int) '\r'; + do_cr_on_newline = 0; goto send; } + regs->data = (unsigned int) ch; /* Wait until the character has been sent? */ if (wait_sent) { |