All of lore.kernel.org
 help / color / mirror / Atom feed
From: Marcelo Tosatti <mtosatti@redhat.com>
To: Avi Kivity <avi@redhat.com>
Cc: kvm@vger.kernel.org
Subject: Re: [PATCH v3 0/4] Fix accessed bit tracking
Date: Mon, 5 Jul 2010 10:45:36 -0300	[thread overview]
Message-ID: <20100705134536.GA17136@amt.cnet> (raw)
In-Reply-To: <1278333553-22731-1-git-send-email-avi@redhat.com>

On Mon, Jul 05, 2010 at 03:39:09PM +0300, Avi Kivity wrote:
> The kvm mmu synchronizes shadow ptes using the mmu lock, however the cpu
> will happily ignore the lock when setting the accessed bit.  This can cause
> the accessed bit to be lost.  Luckily this only results in incorrect page
> selection for swap.
> 
> This patchset fixes the problem by atomically updating the spte when
> needed while taking care of the accessed bit.
> 
> v3: fix i386 pte exchange code in patch 3
>     add missing __set_spte() to drop_spte() in patch 2
> 
> v2: fix incorrect code transformations in first patch
> 
> Avi Kivity (4):
>   KVM: MMU: Introduce drop_spte()
>   KVM: MMU: Move accessed/dirty bit checks from rmap_remove() to
>     drop_spte()
>   KVM: MMU: Atomically check for accessed bit when dropping an spte
>   KVM: MMU: Don't drop accessed bit while updating an spte
> 
>  arch/x86/kvm/mmu.c         |   88 +++++++++++++++++++++++++++++++------------
>  arch/x86/kvm/paging_tmpl.h |   13 +++---
>  2 files changed, 69 insertions(+), 32 deletions(-)

Looks good to me.


      parent reply	other threads:[~2010-07-05 13:55 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-05 12:39 [PATCH v3 0/4] Fix accessed bit tracking Avi Kivity
2010-07-05 12:39 ` [PATCH v3 1/4] KVM: MMU: Introduce drop_spte() Avi Kivity
2010-07-05 12:39 ` [PATCH v3 2/4] KVM: MMU: Move accessed/dirty bit checks from rmap_remove() to drop_spte() Avi Kivity
2010-07-05 12:39 ` [PATCH v3 3/4] KVM: MMU: Atomically check for accessed bit when dropping an spte Avi Kivity
2010-07-05 12:39 ` [PATCH v3 4/4] KVM: MMU: Don't drop accessed bit while updating " Avi Kivity
2010-07-05 13:45 ` Marcelo Tosatti [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=20100705134536.GA17136@amt.cnet \
    --to=mtosatti@redhat.com \
    --cc=avi@redhat.com \
    --cc=kvm@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.