From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH 24/29] KVM: MMU: Track NX state in struct kvm_mmu Date: Sun, 12 Sep 2010 10:06:09 +0200 Message-ID: <4C8C89F1.6020008@redhat.com> References: <1284132667-18620-1-git-send-email-joerg.roedel@amd.com> <1284132667-18620-25-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: In-Reply-To: <1284132667-18620-25-git-send-email-joerg.roedel@amd.com> Sender: linux-kernel-owner@vger.kernel.org List-Id: kvm.vger.kernel.org On 09/10/2010 06:31 PM, Joerg Roedel wrote: > With Nested Paging emulation the NX state between the two > MMU contexts may differ. To make sure that always the right > fault error code is recorded this patch moves the NX state > into struct kvm_mmu so that the code can distinguish between > L1 and L2 NX state. > > --- a/arch/x86/include/asm/kvm_host.h > +++ b/arch/x86/include/asm/kvm_host.h > @@ -259,6 +259,8 @@ struct kvm_mmu { > u64 *lm_root; > u64 rsvd_bits_mask[2][4]; > > + bool nx; > + > u64 pdptrs[4]; /* pae */ > }; This is redundant with mmu->base_role.nx. Please post a follow on patch to use that instead. -- error compiling committee.c: too many arguments to function