From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH v2] fix qemu-kvm sigsegv at exit Date: Sun, 01 Nov 2009 17:39:06 +0200 Message-ID: <4AEDAB9A.3040608@redhat.com> References: <20091026184602.GB6016@amt.cnet> <20091026185849.GA5930@redhat.com> <20091027153346.GA9730@amt.cnet> <4AE81220.2000102@redhat.com> <20091028223845.GA18038@amt.cnet> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Gleb Natapov , kvm To: Marcelo Tosatti Return-path: Received: from mx1.redhat.com ([209.132.183.28]:37347 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752889AbZKAPjE (ORCPT ); Sun, 1 Nov 2009 10:39:04 -0500 Received: from int-mx05.intmail.prod.int.phx2.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.18]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id nA1Fd9sk003291 for ; Sun, 1 Nov 2009 10:39:09 -0500 In-Reply-To: <20091028223845.GA18038@amt.cnet> Sender: kvm-owner@vger.kernel.org List-ID: On 10/29/2009 12:38 AM, Marcelo Tosatti wrote: > >> This will miss an event at the very beginning of the loop (powerdown >> requested before we had a chance to spin up?). I think it should be >> fine since there will be a pending signal which will break us out of >> kvm_cpu_exec() before it has a chance to do anything (i.e. spin in the >> guest). >> >> So, I think it's fine, but please double check the above. >> > That can happen but only with the unpatched version, where > kvm_main_loop_wait eats the signal, sets env->stopped = 1, > and proceeds to kvm_cpu_exec. > With the patch, this is not the case. > > As before, the signal sender will send an IPI with smp_send_reschedule > (and vcpu_enter_guest checks sigpending after disabling interrupts). > Fair enough, double bugfix; applied, thanks. -- error compiling committee.c: too many arguments to function