public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Xiao Guangrong <guangrong.xiao@linux.intel.com>
To: Paolo Bonzini <pbonzini@redhat.com>,
	Linus Torvalds <torvalds@linux-foundation.org>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Gleb Natapov <gleb@kernel.org>, KVM list <kvm@vger.kernel.org>
Subject: Re: [GIT PULL] Early batch of KVM changes for 4.3 merge window
Date: Wed, 2 Sep 2015 06:34:53 +0800	[thread overview]
Message-ID: <55E6280D.1070104@linux.intel.com> (raw)
In-Reply-To: <55E5DA7C.60605@redhat.com>



On 09/02/2015 01:03 AM, Paolo Bonzini wrote:

>
> diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c
> index fb16a8ea3dee..3c745f3abde8 100644
> --- a/arch/x86/kvm/mmu.c
> +++ b/arch/x86/kvm/mmu.c
> @@ -3309,13 +3309,13 @@ walk_shadow_page_get_mmio_spte(struct kvm_vcpu *vcpu, u64 addr, u64 *sptep)
>
>   	walk_shadow_page_lockless_begin(vcpu);
>
> -	for (shadow_walk_init(&iterator, vcpu, addr), root = iterator.level;
> +	for (shadow_walk_init(&iterator, vcpu, addr),
> +		 leaf = root = iterator.level;
>   	     shadow_walk_okay(&iterator);
>   	     __shadow_walk_next(&iterator, spte)) {
> -		leaf = iterator.level;
>   		spte = mmu_spte_get_lockless(iterator.sptep);
>
> -		sptes[leaf - 1] = spte;
> +		sptes[--leaf] = spte;
>
>   		if (!is_shadow_present_pte(spte))
>   			break;
> @@ -3329,7 +3329,7 @@ walk_shadow_page_get_mmio_spte(struct kvm_vcpu *vcpu, u64 addr, u64 *sptep)
>   	if (reserved) {
>   		pr_err("%s: detect reserved bits on spte, addr 0x%llx, dump hierarchy:\n",
>   		       __func__, addr);
> -		while (root >= leaf) {
> +		while (root > leaf) {
>   			pr_err("------ spte 0x%llx level %d.\n",
>   			       sptes[root - 1], root);
>   			root--;
>
>
> But honestly I haven't even compiled it yet.  Xiao, what do you think?
>

It looks good to me!


      reply	other threads:[~2015-09-01 22:40 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-14 23:57 [GIT PULL] Early batch of KVM changes for 4.3 merge window Paolo Bonzini
2015-09-01  0:47 ` Linus Torvalds
2015-09-01  5:45   ` Xiao Guangrong
2015-09-01 17:05     ` Paolo Bonzini
2015-09-01 17:03   ` Paolo Bonzini
2015-09-01 22:34     ` Xiao Guangrong [this message]

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=55E6280D.1070104@linux.intel.com \
    --to=guangrong.xiao@linux.intel.com \
    --cc=gleb@kernel.org \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pbonzini@redhat.com \
    --cc=torvalds@linux-foundation.org \
    /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