4 * This work is licensed under the terms of the GNU GPL, version 2 or later.
5 * See the COPYING file in the top-level directory.
8 /* header to be included in non-Xen-specific code */
13 #include "exec/cpu-common.h"
17 # define CONFIG_XEN_IS_POSSIBLE
20 # define CONFIG_XEN_IS_POSSIBLE
23 #ifdef CONFIG_XEN_IS_POSSIBLE
25 extern bool xen_allowed;
27 #define xen_enabled() (xen_allowed)
29 #ifndef CONFIG_USER_ONLY
30 void xen_hvm_modified_memory(ram_addr_t start, ram_addr_t length);
31 void xen_ram_alloc(ram_addr_t ram_addr, ram_addr_t size,
32 struct MemoryRegion *mr, Error **errp);
35 #else /* !CONFIG_XEN_IS_POSSIBLE */
37 #define xen_enabled() 0
38 #ifndef CONFIG_USER_ONLY
39 static inline void xen_hvm_modified_memory(ram_addr_t start, ram_addr_t length)
43 static inline void xen_ram_alloc(ram_addr_t ram_addr, ram_addr_t size,
44 MemoryRegion *mr, Error **errp)
46 g_assert_not_reached();
50 #endif /* CONFIG_XEN_IS_POSSIBLE */