lkml.org 
[lkml]   [2015]   [Jan]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH -mm 3/3] slub: make dead caches discard free slabs immediately
Hi Joonsoo,

On Tue, Jan 27, 2015 at 05:00:09PM +0900, Joonsoo Kim wrote:
> On Mon, Jan 26, 2015 at 03:55:29PM +0300, Vladimir Davydov wrote:
> > @@ -3381,6 +3390,15 @@ void __kmem_cache_shrink(struct kmem_cache *s)
> > kmalloc(sizeof(struct list_head) * objects, GFP_KERNEL);
> > unsigned long flags;
> >
> > + if (deactivate) {
> > + /*
> > + * Disable empty slabs caching. Used to avoid pinning offline
> > + * memory cgroups by freeable kmem pages.
> > + */
> > + s->cpu_partial = 0;
> > + s->min_partial = 0;
> > + }
> > +
>
> Maybe, kick_all_cpus_sync() is needed here since object would
> be freed asynchronously so they can't see this updated value.

I thought flush_all() should do the trick, no?

Thanks,
Vladimir


\
 
 \ /
  Last update: 2015-01-27 09:41    [W:0.060 / U:0.860 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site