From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [patch 0/2] do not run halted vcpu's Date: Wed, 20 Aug 2008 07:04:36 +0300 Message-ID: <48AB97D4.7030903@qumranet.com> References: <20080801230912.013317832@localhost.localdomain> <48A2BB11.2020909@qumranet.com> <20080815001955.GB14844@dmt.cnet> <48A7C5AC.1020402@qumranet.com> <48A7D613.5030501@qumranet.com> <20080819230726.GA5157@dmt.cnet> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: kvm@vger.kernel.org To: Marcelo Tosatti Return-path: Received: from il.qumranet.com ([212.179.150.194]:36848 "EHLO il.qumranet.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750715AbYHTEEi (ORCPT ); Wed, 20 Aug 2008 00:04:38 -0400 In-Reply-To: <20080819230726.GA5157@dmt.cnet> Sender: kvm-owner@vger.kernel.org List-ID: Marcelo Tosatti wrote: > On Sun, Aug 17, 2008 at 10:41:07AM +0300, Avi Kivity wrote: > >> Avi Kivity wrote: >> >>> Marcelo Tosatti wrote: >>> >>>> KVM: x86: do not execute halted vcpus >>>> >>>> Alright, need_resched was actually checked in vcpu_enter_guest, so this >>>> checks signal_pending too: >>>> >>>> Offline or uninitialized vcpu's can be executed if requested to perform >>>> userspace work. >>>> Follow Avi's suggestion to handle halted vcpu's in the main loop, >>>> simplifying kvm_emulate_halt(). Introduce a new vcpu->requests bit to >>>> indicate events that promote state from halted to running. >>>> >>>> Also standardize vcpu wake sites. >>>> >>>> >>> Applied, thanks. >>> >>> >> This killed reboot, so I reverted it. >> > > Works for me (both UP/SMP, Windows/Linux, guest initiated/system_reset), > and can't find anything obvious in the diff. > > How can it be reproduced? > > Windows UP guest initiated. Since you say it worked, I probably botched something while testing. I'll try again. -- Do not meddle in the internals of kernels, for they are subtle and quick to panic.