[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCHv3] async thread fix - handle EAGAIN/EINTR, remove fp
From: |
Alon Levy |
Subject: |
[Qemu-devel] [PATCHv3] async thread fix - handle EAGAIN/EINTR, remove fprintf |
Date: |
Wed, 29 Jun 2011 13:57:08 +0200 |
---
hw/qxl.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/hw/qxl.c b/hw/qxl.c
index 89e452e..3f84b0c 100644
--- a/hw/qxl.c
+++ b/hw/qxl.c
@@ -1025,13 +1025,15 @@ static void *ioport_write_async(void *arg)
while (true) {
ret = read(d->aio_pipe[0], &io, sizeof(io));
+ if (ret < 0 && (errno == EAGAIN || errno == EINTR)) {
+ continue;
+ }
if (ret != sizeof(io)) {
break;
}
io_port = io->port;
val = io->val;
- fprintf(stderr, "%s: 0x%x\n", __FUNCTION__, io_port);
switch (io_port) {
case QXL_IO_UPDATE_AREA_ASYNC:
qxl_spice_update_area(d, io->update_surface,
--
1.7.5.4
- [Qemu-devel] [PATCHv3] qxl S3&S4 (suspend and hibernate) support, Alon Levy, 2011/06/29
- [Qemu-devel] [PATCHv3] async io: suggested fixes, Alon Levy, 2011/06/29
- [Qemu-devel] [PATCHv3] async thread fix - handle EAGAIN/EINTR, remove fprintf,
Alon Levy <=
- [Qemu-devel] [PATCHv3] qxl: use track_lock instead of wlock for guest_surfaces, Alon Levy, 2011/06/29
- [Qemu-devel] [PATCHv3] qxl: add mode to debugprint on destroy primary, Alon Levy, 2011/06/29
- [Qemu-devel] [PATCHv3] qxl: allow QXL_IO_LOG also in vga, Alon Levy, 2011/06/29
- [Qemu-devel] [PATCHv3] qxl: abort on panic instead of exit, Alon Levy, 2011/06/29
- [Qemu-devel] [PATCHv3] qxl-logger: add timestamp to command log, Alon Levy, 2011/06/29
- [Qemu-devel] [PATCHv3] qxl: update and add debug prints, Alon Levy, 2011/06/29