root / hw / xen_common.h @ dd4239d6
History | View | Annotate | Download (758 Bytes)
1 |
#ifndef QEMU_HW_XEN_COMMON_H
|
---|---|
2 |
#define QEMU_HW_XEN_COMMON_H 1 |
3 |
|
4 |
#include <stddef.h> |
5 |
#include <inttypes.h> |
6 |
|
7 |
#include <xenctrl.h> |
8 |
#include <xs.h> |
9 |
#include <xen/io/xenbus.h> |
10 |
|
11 |
#include "hw.h" |
12 |
#include "xen.h" |
13 |
#include "qemu-queue.h" |
14 |
|
15 |
/*
|
16 |
* tweaks needed to build with different xen versions
|
17 |
* 0x00030205 -> 3.1.0
|
18 |
* 0x00030207 -> 3.2.0
|
19 |
* 0x00030208 -> unstable
|
20 |
*/
|
21 |
#include <xen/xen-compat.h> |
22 |
#if __XEN_LATEST_INTERFACE_VERSION__ < 0x00030205 |
23 |
# define evtchn_port_or_error_t int |
24 |
#endif
|
25 |
#if __XEN_LATEST_INTERFACE_VERSION__ < 0x00030207 |
26 |
# define xc_map_foreign_pages xc_map_foreign_batch
|
27 |
#endif
|
28 |
#if __XEN_LATEST_INTERFACE_VERSION__ < 0x00030208 |
29 |
# define xen_mb() mb()
|
30 |
# define xen_rmb() rmb()
|
31 |
# define xen_wmb() wmb()
|
32 |
#endif
|
33 |
|
34 |
#endif /* QEMU_HW_XEN_COMMON_H */ |