From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:60096) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WT0G5-0006Bb-TX for qemu-devel@nongnu.org; Wed, 26 Mar 2014 22:41:42 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WT0Fs-0006x9-K6 for qemu-devel@nongnu.org; Wed, 26 Mar 2014 22:41:33 -0400 Received: from e23smtp08.au.ibm.com ([202.81.31.141]:56089) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WT0Fr-0006vq-QQ for qemu-devel@nongnu.org; Wed, 26 Mar 2014 22:41:20 -0400 Received: from /spool/local by e23smtp08.au.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 27 Mar 2014 12:41:17 +1000 From: Alexey Kardashevskiy Date: Thu, 27 Mar 2014 13:41:11 +1100 Message-Id: <1395888071-28677-1-git-send-email-aik@ozlabs.ru> Subject: [Qemu-devel] [PATCH] target-ppc: Add @cpu_dt_id into migration stream List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Alexey Kardashevskiy , qemu-ppc@nongnu.org This should prevent the destination guest from misbehaving when the threads number is different in "-smp" command. Signed-off-by: Alexey Kardashevskiy --- 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