xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Mukesh Rathor <mukesh.rathor@oracle.com>
To: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Cc: "Xen-devel@lists.xensource.com" <Xen-devel@lists.xensource.com>,
	david.vrabel@citrix.com
Subject: Re: Huge perf degradation from missing xen_tlb_flush_all
Date: Fri, 26 Oct 2012 17:02:31 -0700	[thread overview]
Message-ID: <20121026170231.31ad2ab8@mantra.us.oracle.com> (raw)
In-Reply-To: <20121026225813.GJ2708@phenom.dumpdata.com>

On Fri, 26 Oct 2012 18:58:13 -0400
Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> wrote:

> On Fri, Oct 26, 2012 at 03:43:11PM -0700, Mukesh Rathor wrote:
> > Hi,
> > 
> Like this I presume (not compile tested):
> diff --git a/arch/x86/xen/mmu.c b/arch/x86/xen/mmu.c
> index 6226c99..dd91c3c 100644
> --- a/arch/x86/xen/mmu.c
> +++ b/arch/x86/xen/mmu.c
> @@ -1288,6 +1288,23 @@ unsigned long xen_read_cr2_direct(void)
>  	return this_cpu_read(xen_vcpu_info.arch.cr2);
>  }
>  
> +void xen_flush_tbl_all(void)
> +{
> +	struct mmuext_op *op;
> +	struct multicall_space mcs;
> +
> +	preempt_disable();
> +
> +	mcs = xen_mc_entry(sizeof(*op));
> +
> +	op = mcs.args;
> +	op->cmd = MMUEXT_TLB_FLUSH_ALL;
> +	MULTI_mmuext_op(mcs.mc, op, 1, NULL, DOMID_SELF);
> +
> +	xen_mc_issue(PARAVIRT_LAZY_MMU);
> +
> +	preempt_enable();
> +}
>  static void xen_flush_tlb(void)
>  {
>  	struct mmuext_op *op;
> @@ -2518,7 +2535,7 @@ int xen_remap_domain_mfn_range(struct
> vm_area_struct *vma, err = 0;
>  out:
>  
> -	flush_tlb_all();
> +	xen_flush_tbl_all();

We should examine other places flush_tlb_all() is called from too.

      reply	other threads:[~2012-10-27  0:02 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-26 22:43 Huge perf degradation from missing xen_tlb_flush_all Mukesh Rathor
2012-10-26 22:58 ` Konrad Rzeszutek Wilk
2012-10-27  0:02   ` Mukesh Rathor [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=20121026170231.31ad2ab8@mantra.us.oracle.com \
    --to=mukesh.rathor@oracle.com \
    --cc=Xen-devel@lists.xensource.com \
    --cc=david.vrabel@citrix.com \
    --cc=konrad.wilk@oracle.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;
as well as URLs for NNTP newsgroup(s).