From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jan Kiszka Subject: Re: [PATCH 10/11] VMX: work around lacking VNMI support Date: Thu, 25 Sep 2008 16:22:37 +0200 Message-ID: <48DB9EAD.2070709@siemens.com> References: <48D74CE6.5060008@siemens.com> <48D7504B.7050102@siemens.com> <48DB5CC3.5010104@siemens.com> <48DB688B.6020307@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 7bit Cc: "Yang, Sheng" , Gleb Natapov , kvm-devel To: Avi Kivity Return-path: Received: from lizzard.sbs.de ([194.138.37.39]:22290 "EHLO lizzard.sbs.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751506AbYIYOYU (ORCPT ); Thu, 25 Sep 2008 10:24:20 -0400 In-Reply-To: <48DB688B.6020307@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: Avi Kivity wrote: > Jan Kiszka wrote: >> Jan Kiszka wrote: >> .. >> >>> Index: b/arch/x86/kvm/vmx.c >>> =================================================================== >>> --- a/arch/x86/kvm/vmx.c >>> +++ b/arch/x86/kvm/vmx.c >>> @@ -90,6 +90,11 @@ struct vcpu_vmx { >>> } rmode; >>> int vpid; >>> bool emulation_required; >>> + >>> + /* Support for vnmi-less CPUs */ >>> + int soft_vnmi_blocked; >>> + ktime_t entry_time; >>> + s64 vnmi_blocked_time; >>> >> >> I meanwhile realized that these states (except entry_time) and probably >> also arch.nmi_pending/injected are things that should be considered when >> the vcpu state is saved and restored, right? What is the right interface >> for this? An extension of kvm_sregs? >> >> > > kvm_sregs can't be extended because that would break the ABI, so we have > to add a new ioctl. > > I have some patches that allow ioctls to be extended, so if that's > accepted, we can avoid the new ioctl. OK. > >> BTW, via which channel is GUEST_INTERRUPTIBILITY_INFO from the vmcs >> saved/restored? I'm currently not seeing any related, CPU-specific code. >> > > Looks like it's missing. As a workaround (or safety bag), is it imaginable to delay or deny VCPU snapshots at not yet fully restorable points (like GUEST_INTERRUPTIBILITY_INFO != 0)? Or stick-your-head-into-the-sand for now? Jan -- Siemens AG, Corporate Technology, CT SE 2 Corporate Competence Center Embedded Linux