[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 15/29] raw-posix: Always check paio_init result
From: |
Kevin Wolf |
Subject: |
[Qemu-devel] [PATCH 15/29] raw-posix: Always check paio_init result |
Date: |
Wed, 3 Aug 2011 16:14:10 +0200 |
From: Frediano Ziglio <address@hidden>
Signed-off-by: Frediano Ziglio <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>
---
block/raw-posix.c | 11 +++++------
1 files changed, 5 insertions(+), 6 deletions(-)
diff --git a/block/raw-posix.c b/block/raw-posix.c
index 6dd7086..c5c9944 100644
--- a/block/raw-posix.c
+++ b/block/raw-posix.c
@@ -230,13 +230,15 @@ static int raw_open_common(BlockDriverState *bs, const
char *filename,
}
}
+ /* We're falling back to POSIX AIO in some cases so init always */
+ if (paio_init() < 0) {
+ goto out_free_buf;
+ }
+
#ifdef CONFIG_LINUX_AIO
if ((bdrv_flags & (BDRV_O_NOCACHE|BDRV_O_NATIVE_AIO)) ==
(BDRV_O_NOCACHE|BDRV_O_NATIVE_AIO)) {
- /* We're falling back to POSIX AIO in some cases */
- paio_init();
-
s->aio_ctx = laio_init();
if (!s->aio_ctx) {
goto out_free_buf;
@@ -245,9 +247,6 @@ static int raw_open_common(BlockDriverState *bs, const char
*filename,
} else
#endif
{
- if (paio_init() < 0) {
- goto out_free_buf;
- }
#ifdef CONFIG_LINUX_AIO
s->use_aio = 0;
#endif
--
1.7.6
- [Qemu-devel] [PATCH 05/29] block: Make BlockDriver method bdrv_eject() return void, (continued)
- [Qemu-devel] [PATCH 05/29] block: Make BlockDriver method bdrv_eject() return void, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 06/29] block: Don't let locked flag prevent medium load, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 07/29] block/vpc.c: Detect too-large vpc file, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 09/29] scsi: Remove references to SET_WINDOW, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 12/29] scsi-disk: Remove 'drive_kind', Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 11/29] scsi: Sanitize command definitions, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 08/29] scsi-disk: Codingstyle fixes, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 13/29] block: Removed unused function bdrv_write_sync, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 14/29] raw-posix: Typo fix, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 10/29] scsi: Remove REZERO_UNIT emulation, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 15/29] raw-posix: Always check paio_init result,
Kevin Wolf <=
- [Qemu-devel] [PATCH 18/29] coroutine: add test-coroutine automated tests, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 16/29] coroutine: introduce coroutines, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 22/29] block: Add bdrv_co_readv/writev emulation, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 19/29] coroutine: add test-coroutine --benchmark-lifecycle, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 20/29] block: Add bdrv_co_readv/writev, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 21/29] block: Emulate AIO functions with bdrv_co_readv/writev, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 29/29] block: Use bdrv_co_* instead of synchronous versions in coroutines, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 28/29] posix-aio-compat: Allow read after EOF, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 23/29] coroutines: Locks, Kevin Wolf, 2011/08/03
- [Qemu-devel] [PATCH 17/29] coroutine: implement coroutines using gthread, Kevin Wolf, 2011/08/03