Received: from eggs.gnu.org ([2001:4830:134:3::10]:51975) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z9qOC-0005kZ-2v for qemu-devel@nongnu.org; Tue, 30 Jun 2015 03:55:32 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Z9qO7-0005a2-Im for qemu-devel@nongnu.org; Tue, 30 Jun 2015 03:55:32 -0400 Received: from e06smtp14.uk.ibm.com ([195.75.94.110]:55107) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z9qO7-0005Zd-8S for qemu-devel@nongnu.org; Tue, 30 Jun 2015 03:55:27 -0400 Received: from /spool/local by e06smtp14.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 30 Jun 2015 08:55:25 +0100 Received: from b06cxnps4074.portsmouth.uk.ibm.com (d06relay11.portsmouth.uk.ibm.com [9.149.109.196]) by d06dlp03.portsmouth.uk.ibm.com (Postfix) with ESMTP id 8DC401B08069 for ; Tue, 30 Jun 2015 08:56:29 +0100 (BST) Received: from d06av01.portsmouth.uk.ibm.com (d06av01.portsmouth.uk.ibm.com [9.149.37.212]) by b06cxnps4074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id t5U7tMOu40304856 for ; Tue, 30 Jun 2015 07:55:23 GMT Received: from d06av01.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av01.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id t5U7tMYS023158 for ; Tue, 30 Jun 2015 01:55:22 -0600 From: Cornelia Huck Date: Tue, 30 Jun 2015 09:55:19 +0200 Message-Id: <1435650920-31945-2-git-send-email-cornelia.huck@de.ibm.com> In-Reply-To: <1435650920-31945-1-git-send-email-cornelia.huck@de.ibm.com> References: <1435650920-31945-1-git-send-email-cornelia.huck@de.ibm.com> Subject: [Qemu-devel] [PATCH for-2.4] s390x/gdb: synchronize cpu state after modifying acrs List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Cornelia Huck , borntraeger@de.ibm.com, jfrei@linux.vnet.ibm.com, agraf@suse.de, David Hildenbrand From: David Hildenbrand Whenever we touch the access control registers, we have to make sure that the values will make it into kvm. Otherwise the change will simply be lost. When synchronizing qemu and kvm, a normal KVM_PUT_RUNTIME_STATE does not take care of these registers. Let's simply trigger a KVM_PUT_FULL_STATE sync, so the values will directly be written to kvm. The performance overhead can be ignored and this is much cleaner than manually writing these registers to kvm via our two supported ways. Reviewed-by: Christian Borntraeger Signed-off-by: David Hildenbrand Signed-off-by: Cornelia Huck --- target-s390x/gdbstub.c | 1 + 1 file changed, 1 insertion(+) diff --git a/target-s390x/gdbstub.c b/target-s390x/gdbstub.c index ddc14a6..31f2049 100644 --- a/target-s390x/gdbstub.c +++ b/target-s390x/gdbstub.c @@ -92,6 +92,7 @@ static int cpu_write_ac_reg(CPUS390XState *env, uint8_t *mem_buf, int n) switch (n) { case S390_A0_REGNUM ... S390_A15_REGNUM: env->aregs[n] = ldl_p(mem_buf); + cpu_synchronize_post_init(ENV_GET_CPU(env)); return 4; default: return 0; -- 2.4.5