[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-stable] [PATCH 21/21] raw-posix: fix bdrv_aio_ioctl
From: |
Michael Roth |
Subject: |
[Qemu-stable] [PATCH 21/21] raw-posix: fix bdrv_aio_ioctl |
Date: |
Wed, 16 Jan 2013 10:49:23 -0600 |
From: Paolo Bonzini <address@hidden>
When the raw-posix aio=thread code was moved from posix-aio-compat.c
to block/raw-posix.c, there was an unintended change to the ioctl code.
The code used to return the ioctl command, which posix_aio_read()
would later morph into a zero. This hack is not necessary anymore,
and in fact breaks scsi-generic (which expects a zero return code).
Remove it.
Cc: address@hidden
Signed-off-by: Paolo Bonzini <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>
(cherry picked from commit b608c8dc02c78ee95455a0989bdf1b41c768b2ef)
Signed-off-by: Michael Roth <address@hidden>
---
block/raw-posix.c | 10 +---------
1 file changed, 1 insertion(+), 9 deletions(-)
diff --git a/block/raw-posix.c b/block/raw-posix.c
index 550c81f..5c6c564 100644
--- a/block/raw-posix.c
+++ b/block/raw-posix.c
@@ -456,15 +456,7 @@ static ssize_t handle_aiocb_ioctl(RawPosixAIOData *aiocb)
return -errno;
}
- /*
- * This looks weird, but the aio code only considers a request
- * successful if it has written the full number of bytes.
- *
- * Now we overload aio_nbytes as aio_ioctl_cmd for the ioctl command,
- * so in fact we return the ioctl command here to make posix_aio_read()
- * happy..
- */
- return aiocb->aio_nbytes;
+ return 0;
}
static ssize_t handle_aiocb_flush(RawPosixAIOData *aiocb)
--
1.7.9.5
- [Qemu-stable] [PATCH 20/21] vfio-pci: Loosen sanity checks to allow future features, (continued)
- [Qemu-stable] [PATCH 20/21] vfio-pci: Loosen sanity checks to allow future features, Michael Roth, 2013/01/16
- [Qemu-stable] [PATCH 14/21] e1000: Discard oversized packets based on SBP|LPE, Michael Roth, 2013/01/16
- [Qemu-stable] [PATCH 18/21] vfio-pci: Make host MSI-X enable track guest, Michael Roth, 2013/01/16
- [Qemu-stable] [PATCH 13/21] qxl+vnc: register a vm state change handler for dummy spice_server, Michael Roth, 2013/01/16
- [Qemu-stable] [PATCH 17/21] target-xtensa: fix search_pc for the last TB opcode, Michael Roth, 2013/01/16
- Re: [Qemu-stable] Patch Round-up for stable 1.3.1, freeze Monday, Michael Tokarev, 2013/01/16
- [Qemu-stable] [PATCH 19/21] pci-assign: Enable MSIX on device to match guest, Michael Roth, 2013/01/16
- [Qemu-stable] [PATCH 15/21] migration: fix migration_bitmap leak, Michael Roth, 2013/01/16
- [Qemu-stable] [PATCH 21/21] raw-posix: fix bdrv_aio_ioctl,
Michael Roth <=
- [Qemu-stable] [PATCH 08/21] seabios: update to e8a76b0f225bba5ba9d63ab227e0a37b3beb1059, Michael Roth, 2013/01/17
- [Qemu-stable] [PATCH 09/21] Update seabios to a810e4e72a0d42c7bc04eda57382f8e019add901, Michael Roth, 2013/01/17
- Re: [Qemu-stable] Patch Round-up for stable 1.3.1, freeze Monday, Doug Goldstein, 2013/01/18