public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Yu Zhang <yu.c.zhang@linux.intel.com>, 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
Subject: Re: [PATCH v2 2/5] KVM: MMU: check guest CR3 reserved bits based on its physical address width.
Date: Thu, 17 Aug 2017 14:31:11 +0200	[thread overview]
Message-ID: <28276aa5-76e5-1826-5b1f-e18a62cd903d@redhat.com> (raw)
In-Reply-To: <1502999558-2517-3-git-send-email-yu.c.zhang@linux.intel.com>

On 17/08/2017 21:52, Yu Zhang wrote:
> +		if (efer & EFER_LMA) {
> +			u64 maxphyaddr;
> +			u32 eax = 0x80000008;
> +
> +			if (ctxt->ops->get_cpuid(ctxt, &eax, NULL, NULL, NULL,
> +						 NO_CHECK_LIMIT)) {
> +				maxphyaddr = eax & 0xff;
> +				rsvd = rsvd_bits(maxphyaddr, 62);
> +			}

You should use 36 here if ctxt->ops->get_cpuid returns false, for
consistency with cpuid_query_maxphyaddr.

Paolo

  reply	other threads:[~2017-08-17 12:31 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-17 19:52 [PATCH v2 0/5] KVM: MMU: 5 level EPT/shadow support Yu Zhang
2017-08-17 19:52 ` [PATCH v2 1/5] KVM: x86: Add return value to kvm_cpuid() Yu Zhang
2017-08-17 12:29   ` Paolo Bonzini
2017-08-17 12:23     ` Yu Zhang
2017-08-17 12:33       ` Yu Zhang
2017-08-17 13:18         ` Paolo Bonzini
2017-08-17 13:17       ` Paolo Bonzini
2017-08-17 13:20         ` Yu Zhang
2017-08-17 14:29           ` Paolo Bonzini
2017-08-17 19:52 ` [PATCH v2 2/5] KVM: MMU: check guest CR3 reserved bits based on its physical address width Yu Zhang
2017-08-17 12:31   ` Paolo Bonzini [this message]
2017-08-17 12:25     ` Yu Zhang
2017-08-17 19:52 ` [PATCH v2 3/5] KVM: MMU: Rename PT64_ROOT_LEVEL to PT64_ROOT_4LEVEL Yu Zhang
2017-08-17 19:52 ` [PATCH v2 4/5] KVM: MMU: Add 5 level EPT & Shadow page table support Yu Zhang
2017-08-17 19:52 ` [PATCH v2 5/5] KVM: MMU: Expose the LA57 feature to VM Yu Zhang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=28276aa5-76e5-1826-5b1f-e18a62cd903d@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=hpa@zytor.com \
    --cc=joro@8bytes.org \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=rkrcmar@redhat.com \
    --cc=tglx@linutronix.de \
    --cc=xiaoguangrong@tencent.com \
    --cc=yu.c.zhang@linux.intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox