Forráskód Böngészése

xen_machine_pv: Use cpu_x86_init() to obtain X86CPU

Needed for moving halted field to CPUState.

Signed-off-by: Andreas Färber <afaerber@suse.de>
Tested-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Andreas Färber 13 éve
szülő
commit
a0595d9eb8
1 módosított fájl, 3 hozzáadás és 1 törlés
  1. 3 1
      hw/xen_machine_pv.c

+ 3 - 1
hw/xen_machine_pv.c

@@ -36,6 +36,7 @@ static void xen_init_pv(ram_addr_t ram_size,
 			const char *initrd_filename,
 			const char *initrd_filename,
 			const char *cpu_model)
 			const char *cpu_model)
 {
 {
+    X86CPU *cpu;
     CPUX86State *env;
     CPUX86State *env;
     DriveInfo *dinfo;
     DriveInfo *dinfo;
     int i;
     int i;
@@ -48,7 +49,8 @@ static void xen_init_pv(ram_addr_t ram_size,
         cpu_model = "qemu32";
         cpu_model = "qemu32";
 #endif
 #endif
     }
     }
-    env = cpu_init(cpu_model);
+    cpu = cpu_x86_init(cpu_model);
+    env = &cpu->env;
     env->halted = 1;
     env->halted = 1;
 
 
     /* Initialize backend core & drivers */
     /* Initialize backend core & drivers */