WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] [PATCH] ioemu: make AIO optional

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [PATCH] ioemu: make AIO optional
From: Samuel Thibault <samuel.thibault@xxxxxxxxxxxxx>
Date: Thu, 7 Feb 2008 14:20:15 +0000
Delivery-date: Thu, 07 Feb 2008 06:21:22 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Mail-followup-to: Samuel Thibault <samuel.thibault@xxxxxxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.12-2006-07-14
ioemu: make AIO optional
(already done upstream)

Signed-off-by: Samuel Thibault <samuel.thibault@xxxxxxxxxxxxx>

diff -r f5493972d237 tools/ioemu/block-raw.c
--- a/tools/ioemu/block-raw.c   Thu Feb 07 14:15:19 2008 +0000
+++ b/tools/ioemu/block-raw.c   Thu Feb 07 14:15:34 2008 +0000
@@ -25,7 +25,9 @@
 #include "block_int.h"
 #include <assert.h>
 #ifndef _WIN32
+#ifndef NO_AIO
 #include <aio.h>
+#endif
 
 #ifndef QEMU_TOOL
 #include "exec-all.h"
@@ -255,6 +257,7 @@ label__raw_write__success:
 /***********************************************************/
 /* Unix AIO using POSIX AIO */
 
+#ifndef NO_AIO
 typedef struct RawAIOCB {
     BlockDriverAIOCB common;
     struct aiocb aiocb;
@@ -480,6 +483,7 @@ static void raw_aio_cancel(BlockDriverAI
         pacb = &acb->next;
     }
 }
+#endif
 
 static void raw_close(BlockDriverState *bs)
 {
@@ -600,10 +604,12 @@ BlockDriver bdrv_raw = {
     raw_create,
     raw_flush,
     
+#ifndef NO_AIO
     .bdrv_aio_read = raw_aio_read,
     .bdrv_aio_write = raw_aio_write,
     .bdrv_aio_cancel = raw_aio_cancel,
     .aiocb_size = sizeof(RawAIOCB),
+#endif
     .protocol_name = "file",
     .bdrv_pread = raw_pread,
     .bdrv_pwrite = raw_pwrite,
@@ -936,10 +942,12 @@ BlockDriver bdrv_host_device = {
     NULL,
     raw_flush,
     
+#ifndef NO_AIO
     .bdrv_aio_read = raw_aio_read,
     .bdrv_aio_write = raw_aio_write,
     .bdrv_aio_cancel = raw_aio_cancel,
     .aiocb_size = sizeof(RawAIOCB),
+#endif
     .bdrv_pread = raw_pread,
     .bdrv_pwrite = raw_pwrite,
     .bdrv_getlength = raw_getlength,

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] [PATCH] ioemu: make AIO optional, Samuel Thibault <=