Received: from eggs.gnu.org ([2001:4830:134:3::10]:54997) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WIEtG-0007rP-1j for qemu-devel@nongnu.org; Tue, 25 Feb 2014 05:05:39 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WIEt5-0005C1-RP for qemu-devel@nongnu.org; Tue, 25 Feb 2014 05:05:29 -0500 Received: from e06smtp14.uk.ibm.com ([195.75.94.110]:57846) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WIEt5-0005Aq-Ij for qemu-devel@nongnu.org; Tue, 25 Feb 2014 05:05:19 -0500 Received: from /spool/local by e06smtp14.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 25 Feb 2014 10:05:17 -0000 Received: from b06cxnps4074.portsmouth.uk.ibm.com (d06relay11.portsmouth.uk.ibm.com [9.149.109.196]) by d06dlp02.portsmouth.uk.ibm.com (Postfix) with ESMTP id BD58B219005E for ; Tue, 25 Feb 2014 10:05:12 +0000 (GMT) Received: from d06av08.portsmouth.uk.ibm.com (d06av08.portsmouth.uk.ibm.com [9.149.37.249]) by b06cxnps4074.portsmouth.uk.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id s1PA53ZV62390372 for ; Tue, 25 Feb 2014 10:05:03 GMT Received: from d06av08.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av08.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id s1PA5E9h018734 for ; Tue, 25 Feb 2014 03:05:15 -0700 From: Christian Borntraeger Date: Tue, 25 Feb 2014 11:05:28 +0100 Message-Id: <1393322735-31277-11-git-send-email-borntraeger@de.ibm.com> In-Reply-To: <1393322735-31277-1-git-send-email-borntraeger@de.ibm.com> References: <1393322735-31277-1-git-send-email-borntraeger@de.ibm.com> Subject: [Qemu-devel] [PATCH 10/17] s390x/sclp: Fixed setting of condition code register List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Anthony Liguori , Peter Maydell Cc: Thomas Huth , qemu-devel , Alexander Graf , Christian Borntraeger , Jens Freimann , Cornelia Huck , Paolo Bonzini , Richard Henderson From: Thomas Huth In the SCLP handler function, the condition code register must only be set if no exception occured. Signed-off-by: Thomas Huth Reviewed-by: Cornelia Huck Signed-off-by: Christian Borntraeger --- target-s390x/kvm.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/target-s390x/kvm.c b/target-s390x/kvm.c index e7b3b13..d3f0d4a 100644 --- a/target-s390x/kvm.c +++ b/target-s390x/kvm.c @@ -451,8 +451,9 @@ static int kvm_sclp_service_call(S390CPU *cpu, struct kvm_run *run, r = sclp_service_call(env, sccb, code); if (r < 0) { enter_pgmcheck(cpu, -r); + } else { + setcc(cpu, r); } - setcc(cpu, r); return 0; } -- 1.8.4.2