#ifdef _WIN32
#define WIN32_LEAN_AND_MEAN
+#define WINVER 0x0501 /* needed for ipv6 bits */
#include <windows.h>
#define fsync _commit
#define lseek _lseeki64
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
+ * invoked. This can create an infinite loop if a bottom half handler
+ * schedules itself. qemu_bh_schedule_idle() avoids this infinite loop by
+ * ensuring that the bottom half isn't executed until the next main loop
+ * iteration.
+ */
+void qemu_bh_schedule_idle(QEMUBH *bh);
void qemu_bh_cancel(QEMUBH *bh);
void qemu_bh_delete(QEMUBH *bh);
int qemu_bh_poll(void);
time_t mktimegm(struct tm *tm);
void *qemu_malloc(size_t size);
+void *qemu_realloc(void *ptr, size_t size);
void *qemu_mallocz(size_t size);
void qemu_free(void *ptr);
char *qemu_strdup(const char *str);
+char *qemu_strndup(const char *str, size_t size);
void *get_mmap_addr(unsigned long size);
/* A load of opaque types so that device init declarations don't have to
pull in all the real definitions. */
typedef struct NICInfo NICInfo;
+typedef struct HCIInfo HCIInfo;
typedef struct AudioState AudioState;
typedef struct BlockDriverState BlockDriverState;
typedef struct DisplayState DisplayState;
void cpu_save(QEMUFile *f, void *opaque);
int cpu_load(QEMUFile *f, void *opaque, int version_id);
+/* Force QEMU to stop what it's doing and service IO */
+void qemu_service_io(void);
+
#endif