From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 809F3C56201 for ; Sat, 28 Nov 2020 03:49:04 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id CBAC12084C for ; Sat, 28 Nov 2020 03:49:03 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b="yy1wBLGc" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org CBAC12084C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux-foundation.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 024D66B005C; Fri, 27 Nov 2020 22:49:03 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id F16D56B005D; Fri, 27 Nov 2020 22:49:02 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id E2CD46B0068; Fri, 27 Nov 2020 22:49:02 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0153.hostedemail.com [216.40.44.153]) by kanga.kvack.org (Postfix) with ESMTP id C934D6B005C for ; Fri, 27 Nov 2020 22:49:02 -0500 (EST) Received: from smtpin24.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id 90FF2180AD82F for ; Sat, 28 Nov 2020 03:49:02 +0000 (UTC) X-FDA: 77532446124.24.knee50_6115aff2738d Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin24.hostedemail.com (Postfix) with ESMTP id 786D21A4A0 for ; Sat, 28 Nov 2020 03:49:02 +0000 (UTC) X-HE-Tag: knee50_6115aff2738d X-Filterd-Recvd-Size: 3218 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by imf44.hostedemail.com (Postfix) with ESMTP for ; Sat, 28 Nov 2020 03:49:01 +0000 (UTC) Received: from localhost.localdomain (c-73-231-172-41.hsd1.ca.comcast.net [73.231.172.41]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id A61A62084C; Sat, 28 Nov 2020 03:49:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1606535340; bh=5YYfeeJILLtIqzGvuUszzdTODlrvQFc5JLrtM/a393E=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=yy1wBLGcF1k+xcJ+07W74o0V5jM1ovuPdcAEx3+vJ6RHOy1B1Tb5HC55Kv3gvrAyh e10YQqRgiTQ/0pm3kGBVgyklj6RdOh/d3NAA4UQY9NRJEr3Pdvwfe+fnAQFkie0IkI wxVC4q+o3Jv0sP0yOjIxiE0z0ZaIEuJvxF16n8F8= Date: Fri, 27 Nov 2020 19:49:00 -0800 From: Andrew Morton To: Balbir Singh Cc: Vlastimil Babka , linux-mm@kvack.org, mhocko@kernel.org, hannes@cmpxchg.org, vdavydov.dev@gmail.com Subject: Re: [PATCH] mm/list_lru: dont make them memcg aware if kmem is disabled Message-Id: <20201127194900.b66f2627a3d52529e401a6f1@linux-foundation.org> In-Reply-To: <20201127092111.GA473773@balbir-desktop> References: <20201126043023.377343-1-bsingharora@gmail.com> <20201127092111.GA473773@balbir-desktop> X-Mailer: Sylpheed 3.5.1 (GTK+ 2.24.31; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Fri, 27 Nov 2020 20:21:11 +1100 Balbir Singh wrote: > On Thu, Nov 26, 2020 at 01:10:18PM +0100, Vlastimil Babka wrote: > > On 11/26/20 5:30 AM, Balbir Singh wrote: > > > When alloc_super() allocates list_lrus for dentries and inodes > > > they are made memcg aware if KMEM is compiled in, we should > > > also check if kmem was disabled at runtime. > > > > > > This overhead is about 32 bytes extra per possible nodes per caller > > > of list_lru_init() > > > > > > Signed-off-by: Balbir Singh > > > > I'd rather export cgroup_memory_nokmem and make cgroup_kmem_disabled() > > inline, put it next to memcg_kmem_enabled() and explain in comments what > > each means. > > > > And ideally, the current memcg_kmem_enabled() should be named e.g. > > memcg_kmem_active(), and then the new cgroup_kmem_disabled() could be named > > memcg_kmem_enabled(). But that's churn and potential future backport hazard, > > so dunno. > > Yes, I am happy with whatever approach works to fast track the patches > > Andrew, thoughts/comments? > Your original changelog doesn't make the case that the patch should be fast tracked, so it looks like there's missing information. Please don't miss information ;) If we're looking for a backportable quickfix for the not-yet-really-explained problem then yes, Vlastimil's suggestion (as a high-priority patch and a separate low-priority patch) sounds good. It is rather a twisty maze of identifiers, so please do comment everything well.