summaryrefslogtreecommitdiff
path: root/hw/char/cadence_uart.c
diff options
context:
space:
mode:
authorEdgar E. Iglesias <edgar.iglesias@gmail.com>2013-06-18 09:22:55 +0200
committerEdgar E. Iglesias <edgar.iglesias@gmail.com>2013-06-24 16:26:52 +0200
commitb52df46551d303ffc79ec39c38440bd8a62ee210 (patch)
treeee8b0c8f5a558e5872d45daafbf7c26b04ef6dc2 /hw/char/cadence_uart.c
parent576156ffed72ab4feb0b752979db86ff8759a2a1 (diff)
downloadqemu-b52df46551d303ffc79ec39c38440bd8a62ee210.tar.gz
qemu-b52df46551d303ffc79ec39c38440bd8a62ee210.tar.bz2
qemu-b52df46551d303ffc79ec39c38440bd8a62ee210.zip
cadence_uart: Handle backend tx errors
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
Diffstat (limited to 'hw/char/cadence_uart.c')
-rw-r--r--hw/char/cadence_uart.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/hw/char/cadence_uart.c b/hw/char/cadence_uart.c
index c2a783430b..205e125de9 100644
--- a/hw/char/cadence_uart.c
+++ b/hw/char/cadence_uart.c
@@ -297,9 +297,7 @@ static void uart_write_tx_fifo(UartState *s, const uint8_t *buf, int size)
return;
}
- while (size) {
- size -= qemu_chr_fe_write(s->chr, buf, size);
- }
+ qemu_chr_fe_write_all(s->chr, buf, size);
}
static void uart_receive(void *opaque, const uint8_t *buf, int size)