Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753275AbdHXNmj (ORCPT ); Thu, 24 Aug 2017 09:42:39 -0400 Received: from mx1.redhat.com ([209.132.183.28]:51002 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752973AbdHXNmi (ORCPT ); Thu, 24 Aug 2017 09:42:38 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com E149DC0587F5 Authentication-Results: ext-mx08.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx08.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=pbonzini@redhat.com Subject: Re: [PATCH v3 4/5] KVM: MMU: Add 5 level EPT & Shadow page table support. To: Yu Zhang , kvm@vger.kernel.org Cc: linux-kernel@vger.kernel.org, rkrcmar@redhat.com, tglx@linutronix.de, mingo@redhat.com, hpa@zytor.com, xiaoguangrong@tencent.com, joro@8bytes.org References: <1503577676-12345-1-git-send-email-yu.c.zhang@linux.intel.com> <1503577676-12345-5-git-send-email-yu.c.zhang@linux.intel.com> From: Paolo Bonzini Message-ID: <6d55fa19-799d-99b1-6992-6f59f0929ca6@redhat.com> Date: Thu, 24 Aug 2017 15:42:34 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: <1503577676-12345-5-git-send-email-yu.c.zhang@linux.intel.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Thu, 24 Aug 2017 13:42:38 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 360 Lines: 16 On 24/08/2017 14:27, Yu Zhang wrote: > /* Update physical-address width */ > vcpu->arch.maxphyaddr = cpuid_query_maxphyaddr(vcpu); > > +#ifdef CONFIG_X86_64 > + if (vcpu->arch.maxphyaddr > 48) > + kvm_mmu_reset_context(vcpu); > +#endif I think CONFIG_X86_64 is not necessary to have maxphyaddr>48? Paolo > kvm_pmu_refresh(vcpu); > return 0; > }