xen: Add xenfv machine
Introduce the Xen FV (Fully Virtualized) machine to Qemu, some more Xen
specific call will be added in further patches.
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Signed-off-by: Alexander Graf <agraf@suse.de>
diff --git a/xen-all.c b/xen-all.c
index e2872f9..0b984b2 100644
--- a/xen-all.c
+++ b/xen-all.c
@@ -9,6 +9,25 @@
#include "hw/xen_common.h"
#include "hw/xen_backend.h"
+/* VCPU Operations, MMIO, IO ring ... */
+
+static void xen_reset_vcpu(void *opaque)
+{
+ CPUState *env = opaque;
+
+ env->halted = 1;
+}
+
+void xen_vcpu_init(void)
+{
+ CPUState *first_cpu;
+
+ if ((first_cpu = qemu_get_cpu(0))) {
+ qemu_register_reset(xen_reset_vcpu, first_cpu);
+ xen_reset_vcpu(first_cpu);
+ }
+}
+
/* Initialise Xen */
int xen_init(void)
@@ -21,3 +40,8 @@
return 0;
}
+
+int xen_hvm_init(void)
+{
+ return 0;
+}