All of lore.kernel.org
 help / color / mirror / Atom feed
From: Wei Liu <wei.liu2@citrix.com>
To: Xen-devel <xen-devel@lists.xenproject.org>
Cc: Andrew Cooper <andrew.cooper3@citrix.com>,
	Wei Liu <wei.liu2@citrix.com>, Jan Beulich <JBeulich@suse.com>
Subject: [PATCH 1/3] x86/mm: introduce trace point for mmio_ro emulation
Date: Wed, 30 Aug 2017 18:11:10 +0100	[thread overview]
Message-ID: <20170830171112.3634-2-wei.liu2@citrix.com> (raw)
In-Reply-To: <20170830171112.3634-1-wei.liu2@citrix.com>

Using ptrw_emulation trace point is wrong.

Signed-off-by: Wei Liu <wei.liu2@citrix.com>
---
 xen/arch/x86/mm.c                | 2 +-
 xen/include/asm-x86/perfc_defn.h | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/xen/arch/x86/mm.c b/xen/arch/x86/mm.c
index 1f23470cef..ed80df02fa 100644
--- a/xen/arch/x86/mm.c
+++ b/xen/arch/x86/mm.c
@@ -5397,7 +5397,7 @@ int mmio_ro_do_page_fault(struct vcpu *v, unsigned long addr,
 
         /* Fallthrough */
     case X86EMUL_RETRY:
-        perfc_incr(ptwr_emulations);
+        perfc_incr(mmio_ro_emulations);
         return EXCRET_fault_fixed;
     }
 
diff --git a/xen/include/asm-x86/perfc_defn.h b/xen/include/asm-x86/perfc_defn.h
index aac9331843..6db8746906 100644
--- a/xen/include/asm-x86/perfc_defn.h
+++ b/xen/include/asm-x86/perfc_defn.h
@@ -30,6 +30,7 @@ PERFCOUNTER(copy_user_faults,       "copy_user faults")
 
 PERFCOUNTER(map_domain_page_count,  "map_domain_page count")
 PERFCOUNTER(ptwr_emulations,        "writable pt emulations")
+PERFCOUNTER(mmio_ro_emulations,     "mmio ro emulations")
 
 PERFCOUNTER(exception_fixed,        "pre-exception fixed")
 
-- 
2.11.0


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

  reply	other threads:[~2017-08-30 17:11 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-30 17:11 [PATCH 0/3] x86/mm: merge ptwr and mmio_ro page fault handlers Wei Liu
2017-08-30 17:11 ` Wei Liu [this message]
2017-08-31  8:12   ` [PATCH 1/3] x86/mm: introduce trace point for mmio_ro emulation Jan Beulich
2017-08-30 17:11 ` [PATCH 2/3] x86/mm: don't wrap x86_emulate_ctxt in ptwr_emulate_ctxt Wei Liu
2017-08-30 17:27   ` Andrew Cooper
2017-08-30 17:11 ` [PATCH 3/3] x86/mm: merge ptwr and mmio_ro page fault handlers Wei Liu
2017-08-30 18:02   ` Andrew Cooper
2017-08-31  9:14     ` Wei Liu

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=20170830171112.3634-2-wei.liu2@citrix.com \
    --to=wei.liu2@citrix.com \
    --cc=JBeulich@suse.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=xen-devel@lists.xenproject.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.