From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH 3/3] KVM: Cache pdptrs Date: Tue, 02 Jun 2009 14:50:36 +0300 Message-ID: <4A25120C.3060107@redhat.com> References: <1243862524-22120-1-git-send-email-avi@redhat.com> <1243862524-22120-4-git-send-email-avi@redhat.com> <20090602090428.GN4062@amd.com> <4A24EC3D.9020507@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: kvm@vger.kernel.org, Marcelo Tosatti , Sheng Yang To: Joerg Roedel Return-path: Received: from mx2.redhat.com ([66.187.237.31]:58999 "EHLO mx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755601AbZFBLui (ORCPT ); Tue, 2 Jun 2009 07:50:38 -0400 In-Reply-To: <4A24EC3D.9020507@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: Avi Kivity wrote: >>> + >>> static void svm_set_vintr(struct vcpu_svm *svm) >>> { >>> svm->vmcb->control.intercept |= 1ULL << INTERCEPT_VINTR; >>> @@ -2286,12 +2298,6 @@ static int handle_exit(struct kvm_run >>> *kvm_run, struct kvm_vcpu *vcpu) >>> } >>> vcpu->arch.cr0 = svm->vmcb->save.cr0; >>> vcpu->arch.cr3 = svm->vmcb->save.cr3; >>> - if (is_paging(vcpu) && is_pae(vcpu) && !is_long_mode(vcpu)) { >>> - if (!load_pdptrs(vcpu, vcpu->arch.cr3)) { >>> - kvm_inject_gp(vcpu, 0); >>> - return 1; >>> - } >>> - } >>> >> >> ... as done here. > > That's a bug... luckily no guests trash their PDPTs after loading CR3. > > I guess I should fix in a separate patch to avoid mixing a bugfix with > a feature. > That could cause a regression if we catch a guest preparing a new pdpte. So I'll leave the code as is. -- error compiling committee.c: too many arguments to function