From: Tim Deegan Subject: Re: [PATCH 13/13] Nested Virtualization: hap-on-hap Date: Mon, 20 Dec 2010 16:35:09 +0000 Message-ID: <20101220163509.GB14760@whitby.uk.xensource.com> References: <201011121945.57564.Christoph.Egger@amd.com> <201012081132.01901.Christoph.Egger@amd.com> <20101208105508.GD9912@whitby.uk.xensource.com> <201012201727.23672.Christoph.Egger@amd.com> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Return-path: Content-Disposition: inline In-Reply-To: <201012201727.23672.Christoph.Egger@amd.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Christoph Egger Cc: "xen-devel@lists.xensource.com" List-Id: xen-devel@lists.xenproject.org At 16:27 +0000 on 20 Dec (1292862443), Christoph Egger wrote: > > > An other vcpu is in VMRUN emulation after a nestedp2m is assigned. > > > It will VMEXIT with a nested page fault. > > > > Why? > > Because the p2m is empty. The MMU can not do a page table walk. > > > > An other vcpu already running l2 guest. > > > It will VMEXIT with a nested page fault immediately. > > > > Hmm. It will exit for the TLB shootdown IPI, but I think you need to > > clear vcpu_nestedhvm(v).nh_p2m on the other vcpu to make sure it doesn't > > re-enter with the p2m you've just recycled. > > The p2m is empty so I don't see a problem when it gets recycled. It's only empty very briefly. You've assigned it to a vcpu which is about to take a nested fault and fill it with entries, right? What happens if the other vcpu is handling an SMI or executing a tight loop of register arithmetic for a few thousand cycles? What stops it seeing the new contents of the p2m? Tim. -- Tim Deegan Principal Software Engineer, Xen Platform Team Citrix Systems UK Ltd. (Company #02937203, SL9 0BG)