From 6bed6df7316bfc9fec149daf7dda374567fecc83 Mon Sep 17 00:00:00 2001 From: SeokYeon Hwang Date: Thu, 11 Dec 2014 15:13:35 +0900 Subject: [PATCH] block: fix compilation error on windows Change-Id: I5a746ab35cb449b2f42da9dff6b592228ebcf495 Signed-off-by: SeokYeon Hwang --- block/raw-win32.c | 20 +------------------- 1 file changed, 1 insertion(+), 19 deletions(-) diff --git a/block/raw-win32.c b/block/raw-win32.c index 7118753..91dd96c 100644 --- a/block/raw-win32.c +++ b/block/raw-win32.c @@ -352,6 +352,7 @@ static int raw_open(BlockDriverState *bs, QDict *options, int flags, goto fail; } #else + // TODO: re-test and re-coding needed open_flags = O_BINARY & ~O_ACCMODE; if (flags & BDRV_O_RDWR) { open_flags |= O_RDWR; @@ -359,25 +360,6 @@ static int raw_open(BlockDriverState *bs, QDict *options, int flags, open_flags |= O_RDONLY; } - /* Use O_DSYNC for write-through caching, no flags for write-back caching, - * and O_DIRECT for no caching. */ - /* - if ((flags & BDRV_O_NOCACHE)) { - open_flags |= O_DIRECT; - } - if (!(flags & BDRV_O_CACHE_WB)) { - open_flags |= O_DSYNC; - } - */ - - if ((flags & BDRV_O_NATIVE_AIO) && aio == NULL) { - aio = win32_aio_init(); - if (aio == NULL) { - ret = -EINVAL; - goto fail; - } - } - ret = qemu_open(filename, open_flags, 0644); if (ret < 0) { error_report("raw_open failed(%d) \n", ret); -- 2.7.4