block-obj-y = cutils.o cache-utils.o qemu-malloc.o qemu-option.o module.o
block-obj-y += nbd.o block.o aio.o aes.o osdep.o
-block-obj-$(CONFIG_AIO) += posix-aio-compat.o
+block-obj-$(CONFIG_POSIX) += posix-aio-compat.o
block-nested-y += cow.o qcow.o vdi.o vmdk.o cloop.o dmg.o bochs.o vpc.o vvfat.o
block-nested-y += qcow2.o qcow2-refcount.o qcow2-cluster.o qcow2-snapshot.o
#include "qemu-log.h"
#include "block_int.h"
#include "module.h"
-#ifdef CONFIG_AIO
#include "posix-aio-compat.h"
-#endif
#ifdef CONFIG_COCOA
#include <paths.h>
return ret;
}
-#ifdef CONFIG_AIO
/***********************************************************/
/* Unix AIO using POSIX AIO */
}
return &acb->common;
}
-#else /* CONFIG_AIO */
-static int posix_aio_init(void)
-{
- return 0;
-}
-#endif /* CONFIG_AIO */
-
static void raw_close(BlockDriverState *bs)
{
.bdrv_create = raw_create,
.bdrv_flush = raw_flush,
-#ifdef CONFIG_AIO
.bdrv_aio_readv = raw_aio_readv,
.bdrv_aio_writev = raw_aio_writev,
-#endif
.bdrv_truncate = raw_truncate,
.bdrv_getlength = raw_getlength,
#endif
s->type = FTYPE_FILE;
-#if defined(__linux__) && defined(CONFIG_AIO)
+#if defined(__linux__)
if (strstart(filename, "/dev/sg", NULL)) {
bs->sg = 1;
}
return ioctl(s->fd, req, buf);
}
-#ifdef CONFIG_AIO
static BlockDriverAIOCB *hdev_aio_ioctl(BlockDriverState *bs,
unsigned long int req, void *buf,
BlockDriverCompletionFunc *cb, void *opaque)
return &acb->common;
}
-#endif
#elif defined(__FreeBSD__)
static int fd_open(BlockDriverState *bs)
.bdrv_create = hdev_create,
.bdrv_flush = raw_flush,
-#ifdef CONFIG_AIO
.bdrv_aio_readv = raw_aio_readv,
.bdrv_aio_writev = raw_aio_writev,
-#endif
.bdrv_read = raw_read,
.bdrv_write = raw_write,
/* generic scsi device */
#ifdef __linux__
.bdrv_ioctl = hdev_ioctl,
-#ifdef CONFIG_AIO
.bdrv_aio_ioctl = hdev_aio_ioctl,
#endif
-#endif
};
#ifdef __linux__
.bdrv_create = hdev_create,
.bdrv_flush = raw_flush,
-#ifdef CONFIG_AIO
.bdrv_aio_readv = raw_aio_readv,
.bdrv_aio_writev = raw_aio_writev,
-#endif
.bdrv_read = raw_read,
.bdrv_write = raw_write,
.bdrv_create = hdev_create,
.bdrv_flush = raw_flush,
-#ifdef CONFIG_AIO
.bdrv_aio_readv = raw_aio_readv,
.bdrv_aio_writev = raw_aio_writev,
-#endif
.bdrv_read = raw_read,
.bdrv_write = raw_write,
/* generic scsi device */
.bdrv_ioctl = hdev_ioctl,
-#ifdef CONFIG_AIO
.bdrv_aio_ioctl = hdev_aio_ioctl,
-#endif
};
#endif /* __linux__ */
.bdrv_create = hdev_create,
.bdrv_flush = raw_flush,
-#ifdef CONFIG_AIO
.bdrv_aio_readv = raw_aio_readv,
.bdrv_aio_writev = raw_aio_writev,
-#endif
.bdrv_read = raw_read,
.bdrv_write = raw_write,
uname_release=""
curses="yes"
curl="yes"
-pthread="yes"
-aio="yes"
io_thread="no"
nptl="yes"
mixemu="no"
bsd="yes"
audio_drv_list="oss"
audio_possible_drivers="oss sdl esd pa"
- aio="no"
;;
NetBSD)
bsd="yes"
EXESUF=".exe"
QEMU_CFLAGS="-DWIN32_LEAN_AND_MEAN -DWINVER=0x501 $QEMU_CFLAGS"
LIBS="-lwinmm -lws2_32 -liphlpapi $LIBS"
- aio=no
fi
# find source path
;;
--enable-mixemu) mixemu="yes"
;;
- --disable-pthread) pthread="no"
- ;;
- --disable-aio) aio="no"
- ;;
--enable-io-thread) io_thread="yes"
;;
--disable-blobs) blobs="no"
echo " --enable-uname-release=R Return R for uname -r in usermode emulation"
echo " --sparc_cpu=V Build qemu for Sparc architecture v7, v8, v8plus, v8plusa, v9"
echo " --disable-vde disable support for vde network"
-echo " --disable-pthread disable pthread support"
-echo " --disable-aio disable AIO support"
echo " --enable-io-thread enable IO thread"
echo " --disable-blobs disable installing provided firmware blobs"
echo " --kerneldir=PATH look for kernel includes in PATH"
# pthread probe
PTHREADLIBS_LIST="-lpthread -lpthreadGC2"
-if test "$pthread" = yes; then
- pthread=no
+pthread=no
cat > $TMPC << EOF
#include <pthread.h>
int main(void) { pthread_create(0,0,0,0); return 0; }
EOF
- for pthread_lib in $PTHREADLIBS_LIST; do
- if compile_prog "" "$pthread_lib" ; then
- pthread=yes
- LIBS="$pthread_lib $LIBS"
- break
- fi
- done
-fi
+for pthread_lib in $PTHREADLIBS_LIST; do
+ if compile_prog "" "$pthread_lib" ; then
+ pthread=yes
+ LIBS="$pthread_lib $LIBS"
+ break
+ fi
+done
if test "$pthread" = no; then
- aio=no
- io_thread=no
+ echo
+ echo "Error: pthread check failed"
+ echo "Make sure to have the pthread libs and headers installed."
+ echo
+ exit 1
fi
##########################################
echo "NPTL support $nptl"
echo "GUEST_BASE $guest_base"
echo "vde support $vde"
-echo "AIO support $aio"
echo "IO thread $io_thread"
echo "Install blobs $blobs"
echo -e "KVM support $kvm"
if test "$xen" = "yes" ; then
echo "CONFIG_XEN=y" >> $config_host_mak
fi
-if test "$aio" = "yes" ; then
- echo "CONFIG_AIO=y" >> $config_host_mak
-fi
if test "$io_thread" = "yes" ; then
echo "CONFIG_IOTHREAD=y" >> $config_host_mak
fi