From: Avi Kivity <a...@redhat.com>

It doesn't exist outside x86, and breaks the build.  Move it to
cpu_synchronize_state() instead (only reading, not writing).

Signed-off-by: Avi Kivity <a...@redhat.com>

diff --git a/monitor.c b/monitor.c
index 5a9fae6..6ff6e1f 100644
--- a/monitor.c
+++ b/monitor.c
@@ -677,7 +677,6 @@ static CPUState *mon_get_cpu(void)
         mon_set_cpu(0);
     }
     cpu_synchronize_state(cur_mon->mon_cpu);
-    kvm_save_mpstate(cur_mon->mon_cpu);
     return cur_mon->mon_cpu;
 }
 
@@ -780,7 +779,6 @@ static void do_info_cpus(Monitor *mon, QObject **ret_data)
         QObject *obj;
 
         cpu_synchronize_state(env);
-        kvm_save_mpstate(env);
 
         obj = qobject_from_jsonf("{ 'CPU': %d, 'current': %i, 'halted': %i }",
                                  env->cpu_index, env == mon->mon_cpu,
diff --git a/qemu-kvm-x86.c b/qemu-kvm-x86.c
index 7b7bc0f..82e362c 100644
--- a/qemu-kvm-x86.c
+++ b/qemu-kvm-x86.c
@@ -1217,6 +1217,7 @@ void kvm_arch_save_regs(CPUState *env)
                 return;
         }
     }
+    kvm_arch_save_mpstate(env);
 }
 
 static void do_cpuid_ent(struct kvm_cpuid_entry2 *e, uint32_t function,
--
To unsubscribe from this list: send the line "unsubscribe kvm-commits" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to