qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] target-ppc: Add @cpu_dt_id into migration stream
@ 2014-03-27  2:41 Alexey Kardashevskiy
  2014-03-27 12:37 ` Andreas Färber
  0 siblings, 1 reply; 12+ messages in thread
From: Alexey Kardashevskiy @ 2014-03-27  2:41 UTC (permalink / raw)
  To: qemu-devel; +Cc: Alexey Kardashevskiy, qemu-ppc

This should prevent the destination guest from misbehaving when
the threads number is different in "-smp" command.

Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
---
 target-ppc/cpu-qom.h | 2 +-
 target-ppc/machine.c | 4 +++-
 2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/target-ppc/cpu-qom.h b/target-ppc/cpu-qom.h
index 5eb56ea..59d0d4a 100644
--- a/target-ppc/cpu-qom.h
+++ b/target-ppc/cpu-qom.h
@@ -91,7 +91,7 @@ struct PowerPCCPU {
     /*< public >*/
 
     CPUPPCState env;
-    int cpu_dt_id;
+    uint32_t cpu_dt_id;
 };
 
 static inline PowerPCCPU *ppc_env_get_cpu(CPUPPCState *env)
diff --git a/target-ppc/machine.c b/target-ppc/machine.c
index 834297e..92529ca 100644
--- a/target-ppc/machine.c
+++ b/target-ppc/machine.c
@@ -500,7 +500,7 @@ static const VMStateInfo vmstate_pvr = {
 
 const VMStateDescription vmstate_ppc_cpu = {
     .name = "cpu",
-    .version_id = 5,
+    .version_id = 6,
     .minimum_version_id = 5,
     .minimum_version_id_old = 4,
     .load_state_old = cpu_load_old,
@@ -537,6 +537,8 @@ const VMStateDescription vmstate_ppc_cpu = {
         VMSTATE_UINT64_EQUAL(env.insns_flags, PowerPCCPU),
         VMSTATE_UINT64_EQUAL(env.insns_flags2, PowerPCCPU),
         VMSTATE_UINT32_EQUAL(env.nb_BATs, PowerPCCPU),
+        VMSTATE_UINT32_EQUAL(cpu_dt_id, PowerPCCPU),
+
         VMSTATE_END_OF_LIST()
     },
     .subsections = (VMStateSubsection []) {
-- 
1.8.4.rc4

^ permalink raw reply related	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2014-04-10 15:11 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-03-27  2:41 [Qemu-devel] [PATCH] target-ppc: Add @cpu_dt_id into migration stream Alexey Kardashevskiy
2014-03-27 12:37 ` Andreas Färber
2014-03-27 12:49   ` Alexey Kardashevskiy
2014-03-27 12:57     ` Peter Maydell
2014-03-27 13:07       ` Alexey Kardashevskiy
2014-04-08  1:26         ` Alexey Kardashevskiy
2014-04-10 12:10           ` [Qemu-devel] [Qemu-ppc] " Alexander Graf
2014-04-10 14:35             ` Alexey Kardashevskiy
2014-04-10 14:41               ` Alexander Graf
2014-04-10 14:44                 ` Alexey Kardashevskiy
2014-04-10 14:49               ` Peter Maydell
2014-04-10 15:11                 ` Alexey Kardashevskiy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).