Received: by 2002:a05:7412:2a8c:b0:e2:908c:2ebd with SMTP id u12csp1634459rdh; Mon, 25 Sep 2023 21:07:05 -0700 (PDT) X-Google-Smtp-Source: AGHT+IF4B6yRsRmT1+3uRgAe50kTrZFBhB7x5f0IF/rZ0/FtPWrTC5hN+QzC4nyVhVHhxmD4jCHE X-Received: by 2002:a17:90b:3588:b0:274:b4ce:7049 with SMTP id mm8-20020a17090b358800b00274b4ce7049mr5898750pjb.34.1695701225051; Mon, 25 Sep 2023 21:07:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695701225; cv=none; d=google.com; s=arc-20160816; b=sSxOWn3Ubr1WnczUxReCc6U+OxGYhp+hmSd3bbOJeDAAn9N2kHTxnwUXuntDQW7IIK tkWzfxf9O98tcjFWlXJI3v7U09SuIatyMcn0kpVX77/l1dMS/NX55C+YtlXIG9VGyQa5 WKjdle9X0+Kkf6ziWU75nYvU4jnlNRMFjfUO/KrNTO5I8NowMIFthIF6jUF4jH+VToS6 np5E0fFFeUmXTpcgW9fx+k4cgVMWxgvBOpnCTA/qVQZUO08hIKVZZvKta/GkrxjXn4Vc AJ/MD6KLtTyV5Na11FgIv+qlLjpmxxeWHfCPNAzlTZ+6ADZ+VZI/PSXYsGf2O8xoU6M+ 1gAQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:dkim-signature:date; bh=KsOaFDbsgZ6azgPIUFRm68AgjbUNl5+lAAmJUzShuJw=; fh=ovqyHRwFpyy6wvoKnJJ3ZY0C2dNmPLTvWqDc0jb6a9U=; b=FG9jbhDzX5VSjM8DWrwrheNWQrNSsTGJxAQfZx4zHKX6irOn2axFU+SPKFKIpLSPxu WqdU3XF55SukedeaY/hhc5XxYFdFNnyyhKkA1BpMPATVV4KpjArPtnOeKeIne2s3nOf8 JhPVHIiC9WVS4r/IJwBbSuPHLgta3Hx6HhXMk5li3B29PYhLaKY2kql+PDrlgZpTtEzM 7mRFKHstvDlppGMXv9hX1OIX7sLHkSGByYtV6JevDg0mi1R+ZpqqkrhYDogyoPxENqXG 6DYu/GFKNlPIO5WkEg0hbLsVETgMG+XrVyA9vgG+dqtcUW7QzOs5iCWb0015utytxMYg MfWg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=OOns7Tyq; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Return-Path: Received: from howler.vger.email (howler.vger.email. [2620:137:e000::3:4]) by mx.google.com with ESMTPS id g2-20020a17090a128200b00273ede74018si11407576pja.187.2023.09.25.21.07.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 25 Sep 2023 21:07:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) client-ip=2620:137:e000::3:4; Authentication-Results: mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=OOns7Tyq; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by howler.vger.email (Postfix) with ESMTP id 07C59834100A; Mon, 25 Sep 2023 19:49:51 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233571AbjIZCtq (ORCPT + 99 others); Mon, 25 Sep 2023 22:49:46 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42358 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230098AbjIZCtq (ORCPT ); Mon, 25 Sep 2023 22:49:46 -0400 Received: from out-206.mta0.migadu.com (out-206.mta0.migadu.com [91.218.175.206]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 254B59F for ; Mon, 25 Sep 2023 19:49:39 -0700 (PDT) Date: Mon, 25 Sep 2023 19:49:31 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1695696577; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=KsOaFDbsgZ6azgPIUFRm68AgjbUNl5+lAAmJUzShuJw=; b=OOns7TyqlCgDQgzlUHreD4BhyUyXY3xo2emigxpQd7k+0klb4BK9Wiegn7DEXkGXiZxsy2 57HdGmEhMcUYkwpgHMPzc4L+kmbQLQMYgcfANprQafT9rN9X8H/hRAYj9mVGEfJhuxxLnT LTSxHhKYeTUSFO83ggkzRFlhAjfeuwM= X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Roman Gushchin To: Michal Hocko Cc: Jeremi Piotrowski , Shakeel Butt , Johannes Weiner , Muchun Song , Greg Kroah-Hartman , stable@vger.kernel.org, patches@lists.linux.dev, Tejun Heo , Andrew Morton , linux-kernel@vger.kernel.org, regressions@lists.linux.dev, mathieu.tortuyaux@gmail.com Subject: Re: [REGRESSION] Re: [PATCH 6.1 033/219] memcg: drop kmem.limit_in_bytes Message-ID: References: <20230917191040.964416434@linuxfoundation.org> <20230917191042.204185566@linuxfoundation.org> <20230920081101.GA12096@linuxonhyperv3.guj3yctzbm1etfxqx2vob5hsef.xx.internal.cloudapp.net> <101987a1-b1ab-429d-af03-b6bdf6216474@linux.microsoft.com> <4eb47d6a-b127-4aad-af30-896c3b9505b4@linux.microsoft.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Migadu-Flow: FLOW_OUT X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (howler.vger.email [0.0.0.0]); Mon, 25 Sep 2023 19:49:51 -0700 (PDT) On Mon, Sep 25, 2023 at 09:41:24AM +0200, Michal Hocko wrote: > On Fri 22-09-23 16:00:30, Roman Gushchin wrote: > > On Wed, Sep 20, 2023 at 03:47:37PM +0200, Michal Hocko wrote: > > > On Wed 20-09-23 15:25:23, Jeremi Piotrowski wrote: > > > > On 9/20/2023 1:07 PM, Michal Hocko wrote: > > > [...] > > > > > I mean, normally I would be just fine reverting this API change because > > > > > it is disruptive but the only way to have the file available and not > > > > > break somebody is to revert 58056f77502f ("memcg, kmem: further > > > > > deprecate kmem.limit_in_bytes") as well. Or to ignore any value written > > > > > there but that sounds rather dubious. Although one could argue this > > > > > would mimic nokmem kernel option. > > > > > > > > > > > > > I just want to make sure we don't introduce yet another new behavior in this legacy > > > > system. I have not seen breakage due to 58056f77502f. Mimicing nokmem sounds good but > > > > does this mean "don't enforce limits" (that should be fine) or "ignore writes to the limit" > > > > (=don't event store the written limit). The latter might have unintended consequences. > > > > > > Yes it would mean that the limit is never enforced. Bad as it is the > > > thing is that the hard limit on kernel memory is broken by design and > > > unfixable. This causes all sorts of unexpected kernel allocation > > > failures that this is simply unsafe to use. > > > > > > All that being said I can see the following options > > > 1) keep the current upstream status and not export the file > > > 2) revert both 58056f77502f and 86327e8eb94 and make it clear > > > that kmem.limit_in_bytes is unsupported so failures or misbehavior > > > as a result of the limit being hit are likely not going to be > > > investigated or fixed. > > > 3) reverting like in 2) but never inforce the limit (so basically nokmem > > > semantic) > > > > Since it's a part of cgroup v1 interface, which is in a frozen state as a whole, > > and there is no significant (performance, code complexity) benefit of > > additionally deprecating kmem.limit_in_bytes, I vote for 2). > > 1) is also an option. > > We have a stronger agrement over 3) > http://lkml.kernel.org/r/ZRE5VJozPZt9bRPy@dhcp22.suse.cz. Please speak > up if you disagree. This works for me too. Thank you! Btw, it seems like going forward we should be more resistant for any cgroup v1 changes and just leave it as it is. Thanks.