lkml.org 
[lkml]   [2018]   [Aug]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [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

    \
     
     \ /
      Last update: 2018-08-24 01:32    [W:2.454 / U:0.024 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site