[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180823233142.GB4487@brain-police>
Date: Fri, 24 Aug 2018 00:31:43 +0100
From: Will Deacon <will.deacon@....com>
To: Peter Zijlstra <peterz@...radead.org>
Cc: torvalds@...ux-foundation.org, luto@...nel.org, x86@...nel.org,
bp@...en8.de, riel@...riel.com, jannh@...gle.com,
ascannell@...gle.com, dave.hansen@...el.com,
linux-kernel@...r.kernel.org, linux-mm@...ck.org,
Nicholas Piggin <npiggin@...il.com>,
David Miller <davem@...emloft.net>,
Martin Schwidefsky <schwidefsky@...ibm.com>,
Michael Ellerman <mpe@...erman.id.au>
Subject: Re: [PATCH 3/4] mm/tlb, x86/mm: Support invalidating TLB caches for
RCU_TABLE_FREE
On Wed, Aug 22, 2018 at 05:55:27PM +0200, Peter Zijlstra wrote:
> On Wed, Aug 22, 2018 at 05:30:15PM +0200, Peter Zijlstra wrote:
> > ARM
> > which later used this put an explicit TLB invalidate in their
> > __p*_free_tlb() functions, and PowerPC-radix followed that example.
>
> > +/*
> > + * If we want tlb_remove_table() to imply TLB invalidates.
> > + */
> > +static inline void tlb_table_invalidate(struct mmu_gather *tlb)
> > +{
> > +#ifdef CONFIG_HAVE_RCU_TABLE_INVALIDATE
> > + /*
> > + * Invalidate page-table caches used by hardware walkers. Then we still
> > + * need to RCU-sched wait while freeing the pages because software
> > + * walkers can still be in-flight.
> > + */
> > + __tlb_flush_mmu_tlbonly(tlb);
> > +#endif
> > +}
>
>
> Nick, Will is already looking at using this to remove the synchronous
> invalidation from __p*_free_tlb() for ARM, could you have a look to see
> if PowerPC-radix could benefit from that too?
>
> Basically, using a patch like the below, would give your tlb_flush()
> information on if tables were removed or not.
Just to say that I have something up and running for arm64 based on this.
I'll post it once it's seen a bit more testing (either tomorrow or Monday).
Will
Powered by blists - more mailing lists