From: Scott Wood <scottwood@freescale.com>
To: Alexander Graf <agraf@suse.de>
Cc: Paul Mackerras <paulus@samba.org>,
kvm@vger.kernel.org, kvm-ppc@vger.kernel.org
Subject: Re: [PATCH 2/4] KVM: PPC: Book3S HV: Add a mechanism for recording modified HPTEs
Date: Mon, 19 Nov 2012 17:20:38 +0000 [thread overview]
Message-ID: <1353345638.10768.1@snotra> (raw)
In-Reply-To: <7B2C8404-8556-4A64-A20A-BDB85F22B94D@suse.de> (from agraf@suse.de on Mon Nov 19 06:36:42 2012)
On 11/19/2012 06:36:42 AM, Alexander Graf wrote:
>
> On 14.11.2012, at 05:32, Paul Mackerras wrote:
>
> > +/*
> > + * Note modification of an HPTE; set the HPTE modified bit
> > + * if it wasn't modified before and anyone is interested.
> > + */
> > +static inline void note_hpte_modification(struct kvm *kvm,
> > + struct revmap_entry *rev)
> > +{
> > + if (!(rev->guest_rpte & HPTE_GR_MODIFIED) &&
> > + atomic_read(&kvm->arch.hpte_mod_interest))
>
> Aren't atomic reads expensive?
No, it's a simple load instruction (done with inline asm so the
compiler can't break it up into smaller loads).
-Scott
WARNING: multiple messages have this Message-ID (diff)
From: Scott Wood <scottwood@freescale.com>
To: Alexander Graf <agraf@suse.de>
Cc: Paul Mackerras <paulus@samba.org>, <kvm@vger.kernel.org>,
<kvm-ppc@vger.kernel.org>
Subject: Re: [PATCH 2/4] KVM: PPC: Book3S HV: Add a mechanism for recording modified HPTEs
Date: Mon, 19 Nov 2012 11:20:38 -0600 [thread overview]
Message-ID: <1353345638.10768.1@snotra> (raw)
In-Reply-To: <7B2C8404-8556-4A64-A20A-BDB85F22B94D@suse.de> (from agraf@suse.de on Mon Nov 19 06:36:42 2012)
On 11/19/2012 06:36:42 AM, Alexander Graf wrote:
>
> On 14.11.2012, at 05:32, Paul Mackerras wrote:
>
> > +/*
> > + * Note modification of an HPTE; set the HPTE modified bit
> > + * if it wasn't modified before and anyone is interested.
> > + */
> > +static inline void note_hpte_modification(struct kvm *kvm,
> > + struct revmap_entry *rev)
> > +{
> > + if (!(rev->guest_rpte & HPTE_GR_MODIFIED) &&
> > + atomic_read(&kvm->arch.hpte_mod_interest))
>
> Aren't atomic reads expensive?
No, it's a simple load instruction (done with inline asm so the
compiler can't break it up into smaller loads).
-Scott
next prev parent reply other threads:[~2012-11-19 17:20 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-14 4:30 [PATCH 0/4] KVM: PPC: Book3S HV: HPT read/write functions for userspace Paul Mackerras
2012-11-14 4:30 ` Paul Mackerras
2012-11-14 4:31 ` [PATCH 1/4] KVM: PPC: Book3S HV: Restructure HPT entry creation code Paul Mackerras
2012-11-14 4:31 ` Paul Mackerras
2012-11-19 12:54 ` Alexander Graf
2012-11-19 12:54 ` Alexander Graf
2012-11-14 4:32 ` [PATCH 2/4] KVM: PPC: Book3S HV: Add a mechanism for recording modified HPTEs Paul Mackerras
2012-11-14 4:32 ` Paul Mackerras
2012-11-19 12:36 ` Alexander Graf
2012-11-19 12:36 ` Alexander Graf
2012-11-19 17:20 ` Scott Wood [this message]
2012-11-19 17:20 ` Scott Wood
2012-11-19 17:40 ` Alexander Graf
2012-11-19 17:40 ` Alexander Graf
2012-11-19 23:25 ` Paul Mackerras
2012-11-19 23:25 ` Paul Mackerras
2012-11-14 4:32 ` [PATCH 3/4] KVM: PPC: Book3S HV: Make a HPTE removal function available Paul Mackerras
2012-11-14 4:32 ` Paul Mackerras
2012-11-14 4:33 ` [PATCH 4/4] KVM: PPC: Book3S HV: Provide a method for userspace to read and write the HPT Paul Mackerras
2012-11-14 4:33 ` Paul Mackerras
2012-11-19 12:53 ` Alexander Graf
2012-11-19 12:53 ` Alexander Graf
2012-11-19 23:59 ` Paul Mackerras
2012-11-19 23:59 ` Paul Mackerras
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=1353345638.10768.1@snotra \
--to=scottwood@freescale.com \
--cc=agraf@suse.de \
--cc=kvm-ppc@vger.kernel.org \
--cc=kvm@vger.kernel.org \
--cc=paulus@samba.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.