summaryrefslogtreecommitdiff
path: root/qemu-common.h
diff options
context:
space:
mode:
authorKevin Wolf <kwolf@redhat.com>2009-10-22 17:54:38 +0200
committerAnthony Liguori <aliguori@us.ibm.com>2009-10-27 12:28:59 -0500
commit9a1e94812913667fe52d01c8ee2b7efe5f404478 (patch)
tree1bce5fd99aac008ef46b0c3fb7ccfb6988d094a4 /qemu-common.h
parent4f999d05f55586ba73494c5ada6d9c5eb9eb800c (diff)
downloadqemu-9a1e94812913667fe52d01c8ee2b7efe5f404478.tar.gz
Introduce contexts for asynchronous callbacks
Add the possibility to use AIO and BHs without allowing foreign callbacks to be run. Basically, you put your own AIOs and BHs in a separate context. For details see the comments in the source. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'qemu-common.h')
-rw-r--r--qemu-common.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/qemu-common.h b/qemu-common.h
index 3e73bf9523..b779cfe69d 100644
--- a/qemu-common.h
+++ b/qemu-common.h
@@ -93,6 +93,10 @@ typedef struct QEMUBH QEMUBH;
typedef void QEMUBHFunc(void *opaque);
+void async_context_push(void);
+void async_context_pop(void);
+int get_async_context_id(void);
+
QEMUBH *qemu_bh_new(QEMUBHFunc *cb, void *opaque);
void qemu_bh_schedule(QEMUBH *bh);
/* Bottom halfs that are scheduled from a bottom half handler are instantly