From patchwork Fri Feb 4 15:47:24 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marcelo Tosatti X-Patchwork-Id: 81898 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id BF3E7B713C for ; Sat, 5 Feb 2011 02:51:19 +1100 (EST) Received: from localhost ([127.0.0.1]:50045 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PlNwK-00065x-VI for incoming@patchwork.ozlabs.org; Fri, 04 Feb 2011 10:51:17 -0500 Received: from [140.186.70.92] (port=51642 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PlNut-000613-OR for qemu-devel@nongnu.org; Fri, 04 Feb 2011 10:49:50 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PlNus-0007xk-9y for qemu-devel@nongnu.org; Fri, 04 Feb 2011 10:49:47 -0500 Received: from mx1.redhat.com ([209.132.183.28]:11109) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PlNus-0007x6-2z for qemu-devel@nongnu.org; Fri, 04 Feb 2011 10:49:46 -0500 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p14Fnj3X031907 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 4 Feb 2011 10:49:45 -0500 Received: from ns3.rdu.redhat.com (ns3.rdu.redhat.com [10.11.255.199]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id p14Fni6d020724; Fri, 4 Feb 2011 10:49:45 -0500 Received: from amt.cnet (vpn2-8-97.ams2.redhat.com [10.36.8.97]) by ns3.rdu.redhat.com (8.13.8/8.13.8) with ESMTP id p14Fnhl8002221; Fri, 4 Feb 2011 10:49:44 -0500 Received: from amt.cnet (localhost.localdomain [127.0.0.1]) by amt.cnet (Postfix) with ESMTP id 233C965214E; Fri, 4 Feb 2011 13:48:55 -0200 (BRST) Received: (from marcelo@localhost) by amt.cnet (8.14.4/8.14.4/Submit) id p14FmpUN017701; Fri, 4 Feb 2011 13:48:51 -0200 From: Marcelo Tosatti To: Anthony Liguori Date: Fri, 4 Feb 2011 13:47:24 -0200 Message-Id: In-Reply-To: References: X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 209.132.183.28 Cc: Jan Kiszka , Marcelo Tosatti , qemu-devel@nongnu.org, kvm@vger.kernel.org Subject: [Qemu-devel] [PATCH 21/23] kvm: Leave kvm_cpu_exec directly after KVM_EXIT_SHUTDOWN X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org From: Jan Kiszka The reset we issue on KVM_EXIT_SHUTDOWN implies that we should also leave the VCPU loop. As we now check for exit_request which is set by qemu_system_reset_request, this bug is no longer critical. Still it's an unneeded extra turn. Signed-off-by: Jan Kiszka Signed-off-by: Marcelo Tosatti --- kvm-all.c | 1 - 1 files changed, 0 insertions(+), 1 deletions(-) diff --git a/kvm-all.c b/kvm-all.c index 4729ec5..42dfed8 100644 --- a/kvm-all.c +++ b/kvm-all.c @@ -963,7 +963,6 @@ int kvm_cpu_exec(CPUState *env) case KVM_EXIT_SHUTDOWN: DPRINTF("shutdown\n"); qemu_system_reset_request(); - ret = 1; break; case KVM_EXIT_UNKNOWN: fprintf(stderr, "KVM: unknown exit, hardware reason %" PRIx64 "\n",