diff options
author | Antony Pavlov <antonynpavlov@gmail.com> | 2013-08-31 21:22:39 +0400 |
---|---|---|
committer | Michael Walle <michael@walle.cc> | 2014-02-04 19:34:29 +0100 |
commit | b2c623a3d9c88fb1d3bbbbe97364dc65bc6ab363 (patch) | |
tree | f86a59bf56e6dd08c4ef362b71704081ee1af954 /hw/char | |
parent | f40c49ac9f89ee52b6015904c9005b734a73487a (diff) | |
download | qemu-b2c623a3d9c88fb1d3bbbbe97364dc65bc6ab363.zip qemu-b2c623a3d9c88fb1d3bbbbe97364dc65bc6ab363.tar.gz qemu-b2c623a3d9c88fb1d3bbbbe97364dc65bc6ab363.tar.bz2 |
milkymist-uart: use qemu_chr_fe_write_all() instead of qemu_chr_fe_write()
qemu_chr_fe_write() is capable of returning 0
to indicate EAGAIN (and friends) and we don't
handle this.
Just change it to qemu_chr_fe_write_all() to fix.
Reported-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
Acked-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
Signed-off-by: Michael Walle <michael@walle.cc>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw/char')
-rw-r--r-- | hw/char/milkymist-uart.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/char/milkymist-uart.c b/hw/char/milkymist-uart.c index 2c52a0f..da51f82 100644 --- a/hw/char/milkymist-uart.c +++ b/hw/char/milkymist-uart.c @@ -124,7 +124,7 @@ static void uart_write(void *opaque, hwaddr addr, uint64_t value, switch (addr) { case R_RXTX: if (s->chr) { - qemu_chr_fe_write(s->chr, &ch, 1); + qemu_chr_fe_write_all(s->chr, &ch, 1); } s->regs[R_STAT] |= STAT_TX_EVT; break; |