diff options
author | achingupta <achin.gupta@arm.com> | 2014-06-12 09:15:06 +0100 |
---|---|---|
committer | achingupta <achin.gupta@arm.com> | 2014-06-12 09:15:06 +0100 |
commit | 2966dc2cf5919310fa95c6c12d0d4a7cfab10fdc (patch) | |
tree | 0aacecd4c872d955a65a45e03c694f63bd1b9c51 | |
parent | ca1e6b63c4cc78bbad6ff89f8d7461446a785fa7 (diff) | |
parent | d831af90a3788c705bfdd49c9f9548b34a647f80 (diff) |
Merge pull request #127 from sandrine-bailleux/sb/fix-pl011-fifo-polling
PL011: Fix a bug in the UART FIFO polling
-rw-r--r-- | drivers/arm/pl011/pl011_console.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/arm/pl011/pl011_console.c b/drivers/arm/pl011/pl011_console.c index 0e82aa21..a26c00ed 100644 --- a/drivers/arm/pl011/pl011_console.c +++ b/drivers/arm/pl011/pl011_console.c @@ -65,8 +65,10 @@ void console_init(unsigned long base_addr) } -#define WAIT_UNTIL_UART_FREE(base) while ((pl011_read_fr(base)\ - & PL011_UARTFR_TXFF) == 1) +#define WAIT_UNTIL_UART_FREE(base) \ + while ((pl011_read_fr(base) & PL011_UARTFR_TXFF)) \ + continue + int console_putc(int c) { assert(uart_base); |