fix panic serial code

panic_putc was doing an infinite loop on platforms with a UART FIFO.
(e.g. LM4F)

Signed-off-by: Vincent Palatin <vpalatin@chromium.org>

BUG=chrome-os-partner:10825
TEST=on Link EVT and Lucas DVT, type "rw 1" in the EC serial console and
see the panic trace.

Change-Id: I47f43183e6e938b88874c80244430ddf88c5a567
Reviewed-on: https://gerrit.chromium.org/gerrit/26052
Reviewed-by: Randall Spangler <rspangler@chromium.org>
Tested-by: Vincent Palatin <vpalatin@chromium.org>
Commit-Ready: Vincent Palatin <vpalatin@chromium.org>
This commit is contained in:
Vincent Palatin
2012-06-25 21:09:52 +00:00
committed by Gerrit
parent 900c0215b4
commit b8d7d8fc44

View File

@@ -35,8 +35,7 @@ void panic_putc(int ch)
if (ch == '\n')
panic_putc('\r');
uart_write_char(ch);
while (uart_tx_ready())
;
uart_tx_flush();
}