From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH 02/22] KVM: MMU: Make tdp_enabled a mmu-context parameter Date: Tue, 27 Apr 2010 15:06:01 +0300 Message-ID: <4BD6D329.5060204@redhat.com> References: <1272364712-17425-1-git-send-email-joerg.roedel@amd.com> <1272364712-17425-3-git-send-email-joerg.roedel@amd.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Marcelo Tosatti , kvm@vger.kernel.org, linux-kernel@vger.kernel.org To: Joerg Roedel Return-path: Received: from mx1.redhat.com ([209.132.183.28]:5240 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753626Ab0D0MGF (ORCPT ); Tue, 27 Apr 2010 08:06:05 -0400 In-Reply-To: <1272364712-17425-3-git-send-email-joerg.roedel@amd.com> Sender: kvm-owner@vger.kernel.org List-ID: On 04/27/2010 01:38 PM, Joerg Roedel wrote: > This patch changes the tdp_enabled flag from its global > meaning to the mmu-context and renames it to direct_map > there. This is necessary for Nested SVM with emulation of > Nested Paging where we need an extra MMU context to shadow > the Nested Nested Page Table. > > @@ -2423,6 +2424,7 @@ static int init_kvm_softmmu(struct kvm_vcpu *vcpu) > r = paging32_init_context(vcpu); > > vcpu->arch.mmu.base_role.cr4_pae = !!is_pae(vcpu); > + vcpu->arch.mmu.direct_map = false; > > return r; > } > We could also set direct_map = true for real mode, would probably simplify some later logic (can be cleaned up later, no need to update now). -- error compiling committee.c: too many arguments to function