summaryrefslogtreecommitdiff
path: root/aio-posix.c
diff options
context:
space:
mode:
authorMatthew Fortune <Matthew.Fortune@imgtec.com>2016-02-23 15:42:14 +0000
committerStefan Hajnoczi <stefanha@redhat.com>2016-03-17 09:50:14 +0000
commit147dfab747dd1720cb6350b6b746ca84e15f9a24 (patch)
tree08e76f26143a5eb91ef055cb87a4c3b70d6b6ed7 /aio-posix.c
parent8c4575472494a5dfedfe05e7b58ca9ce3872ad56 (diff)
downloadqemu-147dfab747dd1720cb6350b6b746ca84e15f9a24.tar.gz
aio-posix: Change CONFIG_EPOLL to CONFIG_EPOLL_CREATE1
CONFIG_EPOLL was being used to guard epoll_create1 which results in build failures on CentOS 5. Signed-off-by: Matthew Fortune <matthew.fortune@imgtec.com> Reviewed-by: Fam Zheng <famz@redhat.com> Message-id: 6D39441BF12EF246A7ABCE6654B023536BB85D08@hhmail02.hh.imgtec.org Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'aio-posix.c')
-rw-r--r--aio-posix.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/aio-posix.c b/aio-posix.c
index fa7f8ab2a5..7fd565fbde 100644
--- a/aio-posix.c
+++ b/aio-posix.c
@@ -18,7 +18,7 @@
#include "block/block.h"
#include "qemu/queue.h"
#include "qemu/sockets.h"
-#ifdef CONFIG_EPOLL
+#ifdef CONFIG_EPOLL_CREATE1
#include <sys/epoll.h>
#endif
@@ -33,7 +33,7 @@ struct AioHandler
QLIST_ENTRY(AioHandler) node;
};
-#ifdef CONFIG_EPOLL
+#ifdef CONFIG_EPOLL_CREATE1
/* The fd number threashold to switch to epoll */
#define EPOLL_ENABLE_THRESHOLD 64
@@ -483,7 +483,7 @@ bool aio_poll(AioContext *ctx, bool blocking)
void aio_context_setup(AioContext *ctx, Error **errp)
{
-#ifdef CONFIG_EPOLL
+#ifdef CONFIG_EPOLL_CREATE1
assert(!ctx->epollfd);
ctx->epollfd = epoll_create1(EPOLL_CLOEXEC);
if (ctx->epollfd == -1) {