[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <DM5PR21MB0476915D204F850F7F7C1475A0880@DM5PR21MB0476.namprd21.prod.outlook.com>
Date: Thu, 10 Aug 2017 18:59:13 +0000
From: KY Srinivasan <kys@...rosoft.com>
To: Peter Zijlstra <peterz@...radead.org>,
Simon Xiao <sixiao@...rosoft.com>,
Haiyang Zhang <haiyangz@...rosoft.com>,
Jork Loeser <Jork.Loeser@...rosoft.com>,
Stephen Hemminger <sthemmin@...rosoft.com>,
"torvalds@...ux-foundation.org" <torvalds@...ux-foundation.org>,
"luto@...nel.org" <luto@...nel.org>,
"hpa@...or.com" <hpa@...or.com>,
"vkuznets@...hat.com" <vkuznets@...hat.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"rostedt@...dmis.org" <rostedt@...dmis.org>,
"andy.shevchenko@...il.com" <andy.shevchenko@...il.com>,
"tglx@...utronix.de" <tglx@...utronix.de>,
"mingo@...nel.org" <mingo@...nel.org>
CC: "linux-tip-commits@...r.kernel.org"
<linux-tip-commits@...r.kernel.org>
Subject: RE: [tip:x86/platform] x86/hyper-v: Use hypercall for remote TLB
flush
> -----Original Message-----
> From: Peter Zijlstra [mailto:peterz@...radead.org]
> Sent: Thursday, August 10, 2017 11:57 AM
> To: Simon Xiao <sixiao@...rosoft.com>; Haiyang Zhang
> <haiyangz@...rosoft.com>; Jork Loeser <Jork.Loeser@...rosoft.com>;
> Stephen Hemminger <sthemmin@...rosoft.com>; torvalds@...ux-
> foundation.org; luto@...nel.org; hpa@...or.com; vkuznets@...hat.com;
> linux-kernel@...r.kernel.org; rostedt@...dmis.org;
> andy.shevchenko@...il.com; tglx@...utronix.de; KY Srinivasan
> <kys@...rosoft.com>; mingo@...nel.org
> Cc: linux-tip-commits@...r.kernel.org
> Subject: Re: [tip:x86/platform] x86/hyper-v: Use hypercall for remote TLB
> flush
>
> On Thu, Aug 10, 2017 at 11:21:49AM -0700, tip-bot for Vitaly Kuznetsov
> wrote:
> > Commit-ID: 2ffd9e33ce4af4e8cfa3e17bf493defe8474e2eb
> > Gitweb:
> https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fgit.kern
> el.org%2Ftip%2F2ffd9e33ce4af4e8cfa3e17bf493defe8474e2eb&data=02%7C
> 01%7Ckys%40microsoft.com%7C2537372f38d3414e999e08d4e0218ec8%7C72
> f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C636379882129411812&sdata
> =odsJ2NnQdD8LCEtDPfVf5rL%2F2sQX4fKUhlqVSjKhjCI%3D&reserved=0
> > Author: Vitaly Kuznetsov <vkuznets@...hat.com>
> > AuthorDate: Wed, 2 Aug 2017 18:09:19 +0200
> > Committer: Ingo Molnar <mingo@...nel.org>
> > CommitDate: Thu, 10 Aug 2017 20:16:44 +0200
> >
> > x86/hyper-v: Use hypercall for remote TLB flush
> >
> > Hyper-V host can suggest us to use hypercall for doing remote TLB flush,
> > this is supposed to work faster than IPIs.
> >
> > Implementation details: to do HvFlushVirtualAddress{Space,List} hypercalls
> > we need to put the input somewhere in memory and we don't really want
> to
> > have memory allocation on each call so we pre-allocate per cpu memory
> areas
> > on boot.
> >
> > pv_ops patching is happening very early so we need to separate
> > hyperv_setup_mmu_ops() and hyper_alloc_mmu().
> >
> > It is possible and easy to implement local TLB flushing too and there is
> > even a hint for that. However, I don't see a room for optimization on the
> > host side as both hypercall and native tlb flush will result in vmexit. The
> > hint is also not set on modern Hyper-V versions.
>
> Hold on.. if we don't IPI for TLB invalidation. What serializes our
> software page table walkers like fast_gup() ?
Hypervisor may implement this functionality via an IPI.
K. Y
Powered by blists - more mailing lists