From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-it0-f71.google.com (mail-it0-f71.google.com [209.85.214.71]) by kanga.kvack.org (Postfix) with ESMTP id C4AD86B0069 for ; Thu, 6 Oct 2016 02:27:11 -0400 (EDT) Received: by mail-it0-f71.google.com with SMTP id l13so45565843itl.0 for ; Wed, 05 Oct 2016 23:27:11 -0700 (PDT) Received: from lgeamrelo12.lge.com (LGEAMRELO12.lge.com. [156.147.23.52]) by mx.google.com with ESMTP id p1si16387022iop.243.2016.10.05.23.27.10 for ; Wed, 05 Oct 2016 23:27:11 -0700 (PDT) Date: Thu, 6 Oct 2016 15:27:08 +0900 From: Joonsoo Kim Subject: Re: [PATCH 2/2] slub: move synchronize_sched out of slab_mutex on shrink Message-ID: <20161006062708.GA2525@js1304-P5Q-DELUXE> References: <0a10d71ecae3db00fb4421bcd3f82bcc911f4be4.1475329751.git.vdavydov.dev@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <0a10d71ecae3db00fb4421bcd3f82bcc911f4be4.1475329751.git.vdavydov.dev@gmail.com> Sender: owner-linux-mm@kvack.org List-ID: To: Vladimir Davydov Cc: Andrew Morton , linux-mm@kvack.org, linux-kernel@vger.kernel.org, Christoph Lameter , David Rientjes , Johannes Weiner , Michal Hocko , Pekka Enberg , Doug Smythies Ccing Doug, original reporter. On Sat, Oct 01, 2016 at 04:56:48PM +0300, Vladimir Davydov wrote: > synchronize_sched() is a heavy operation and calling it per each cache > owned by a memory cgroup being destroyed may take quite some time. What > is worse, it's currently called under the slab_mutex, stalling all works > doing cache creation/destruction. > > Actually, there isn't much point in calling synchronize_sched() for each > cache - it's enough to call it just once - after setting cpu_partial for > all caches and before shrinking them. This way, we can also move it out > of the slab_mutex, which we have to hold for iterating over the slab > cache list. > > Link: https://bugzilla.kernel.org/show_bug.cgi?id=172991 > Signed-off-by: Vladimir Davydov > Reported-by: Doug Smythies > Cc: Christoph Lameter > Cc: David Rientjes > Cc: Johannes Weiner > Cc: Joonsoo Kim > Cc: Michal Hocko > Cc: Pekka Enberg Acked-by: Joonsoo Kim These two patches should be sent to stable. Isn't it? Thanks. -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: email@kvack.org