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 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 92B88C54EE9 for ; Wed, 7 Sep 2022 16:13:23 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 169E86B0072; Wed, 7 Sep 2022 12:13:23 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 0F27C8D0001; Wed, 7 Sep 2022 12:13:23 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id ED4196B0074; Wed, 7 Sep 2022 12:13:22 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id D96956B0072 for ; Wed, 7 Sep 2022 12:13:22 -0400 (EDT) Received: from smtpin29.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay08.hostedemail.com (Postfix) with ESMTP id A917414018A for ; Wed, 7 Sep 2022 16:13:22 +0000 (UTC) X-FDA: 79885784244.29.A1FB153 Received: from mail-ed1-f42.google.com (mail-ed1-f42.google.com [209.85.208.42]) by imf11.hostedemail.com (Postfix) with ESMTP id 66BBF40071 for ; Wed, 7 Sep 2022 16:13:22 +0000 (UTC) Received: by mail-ed1-f42.google.com with SMTP id q21so12826808edc.9 for ; Wed, 07 Sep 2022 09:13:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date; bh=CdfonG3Daj+a+DRtXJOAxXJ4mGEklFmGRagUZWD+cvk=; b=Z1rGqY1ffwxgupGWkW6pQ+f5YhPrqQnvr/EKxVoO5zamDhVUf5LFJW6hwj/MoDMCGo rCiXcvnPDuekOgwxJPi7xLOUMAr3g7SVrx3Ijy6giUgCxCU3P+Cy7G1iQu/YtGCS+X09 jq4RJykUP1fu4qw2jrQEP4nQpO546ANxS8bWLYiBJyJ/hfR7W41j9LbGe11pSK1HFXfa qvA7OgVXsIBXah6n3P8RTNJzcNSYepd8caKdsjGhuNOJcLoMOnRsTag7aQlQQCeLeGjL rVIKJrbqOqCz0HBcs/YudYF7oXU3fUx3qoEnHjsrRgckkwr9OlrcaW5HMhkj7XH3PibM Ur9Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date; bh=CdfonG3Daj+a+DRtXJOAxXJ4mGEklFmGRagUZWD+cvk=; b=as/IueyRovYBaAid/ehOOYJu0/EowNHxNzZbMW8VhLj4PQf7aGYQ5nKsGwpNVQ8ug6 e0bruT1jgTOMIWcFMbrt8ry3vPhT5cQoOpEem9BRQfMVjYAIrSr3RrmsFZKdkiL164FO sKfI+pQhUQBvK2h7lnnXWkviWkc02MY2fj9UWM9jwHi7qFyPYoGLCjaPkrwVWIBOaplK PYHzVC7kvODwUHSKx7FQsij0tp0AfKLcxBj6lZkC+sPpkl4ymjMhNzM2jXvjsjMXFKy+ m8FyJVDK1U+/FYbbqT78bPHhFcWQ4XIzGpXi0Frm3TCMGh294M5pm+w75I5XCaYf926Y 0bMQ== X-Gm-Message-State: ACgBeo2A4ZEVgm3ujeGI6T4732CEAPPfMiz8R2is9NpnayiohL1ASL8p PfBdU0aB6dPNv7AlG15l3OKSuhutdXXXoEIKfzY= X-Google-Smtp-Source: AA6agR5+UidDgRUpY92PgyIJue81nkq58ErJIlNMk27idwNe8XRuenn1OA+5aUlnmCwefOHw+9bH0poa2V8hdxGi3LA= X-Received: by 2002:a05:6402:28cb:b0:43b:c6d7:ef92 with SMTP id ef11-20020a05640228cb00b0043bc6d7ef92mr3758898edb.333.1662567201046; Wed, 07 Sep 2022 09:13:21 -0700 (PDT) MIME-Version: 1.0 References: <20220902023003.47124-1-laoar.shao@gmail.com> In-Reply-To: From: Alexei Starovoitov Date: Wed, 7 Sep 2022 09:13:09 -0700 Message-ID: Subject: Re: [PATCH bpf-next v3 00/13] bpf: Introduce selectable memcg for bpf map To: Tejun Heo Cc: Yafang Shao , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , Johannes Weiner , Michal Hocko , Roman Gushchin , Shakeel Butt , Muchun Song , Andrew Morton , Zefan Li , "open list:CONTROL GROUP (CGROUP)" , Network Development , bpf , linux-mm Content-Type: text/plain; charset="UTF-8" ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1662567202; a=rsa-sha256; cv=none; b=2iyb26Zfe3T/NLMNIW4I4Y3gcgErGCwnvL2uw8kgUfP1Zs5VE53ewhG0fBq+51TlkEHNnG atERy/AIX645qsJFJv+D93RNl9oEKS1zq5l2v6kXFsVzR0rbCSlMi9fallqJoGUix00fIg hvJqtss/+hG38Yt8bzpwNGPl7RyzpfQ= ARC-Authentication-Results: i=1; imf11.hostedemail.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=Z1rGqY1f; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (imf11.hostedemail.com: domain of alexei.starovoitov@gmail.com designates 209.85.208.42 as permitted sender) smtp.mailfrom=alexei.starovoitov@gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1662567202; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=CdfonG3Daj+a+DRtXJOAxXJ4mGEklFmGRagUZWD+cvk=; b=CRHHRbtO5DBx2yf8MMytzTSrTdwSfpDG8T24qMkWLNUeGuTYUhTNQvcQVNdvH2Pf+fYVRY i/7iSp1J16IwwTIprGK5rKdEhiPW0DzKiPdKRcVgWKRMUcL9D5utnr2+RdvB4YycbFSx5v VLbFrnVVjaRAair7p+Lo5rE6W5nUibM= X-Rspamd-Server: rspam07 X-Rspamd-Queue-Id: 66BBF40071 Authentication-Results: imf11.hostedemail.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=Z1rGqY1f; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (imf11.hostedemail.com: domain of alexei.starovoitov@gmail.com designates 209.85.208.42 as permitted sender) smtp.mailfrom=alexei.starovoitov@gmail.com X-Stat-Signature: g41zrsh4sj1pci5go5nqetbsoncpoqjh X-Rspam-User: X-HE-Tag: 1662567202-612562 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 Wed, Sep 7, 2022 at 8:45 AM Tejun Heo wrote: > > On Wed, Sep 07, 2022 at 05:43:31AM -1000, Tejun Heo wrote: > > Hello, > > > > On Fri, Sep 02, 2022 at 02:29:50AM +0000, Yafang Shao wrote: > > ... > > > This patchset tries to resolve the above two issues by introducing a > > > selectable memcg to limit the bpf memory. Currently we only allow to > > > select its ancestor to avoid breaking the memcg hierarchy further. > > > Possible use cases of the selectable memcg as follows, > > > > As discussed in the following thread, there are clear downsides to an > > interface which requires the users to specify the cgroups directly. > > > > https://lkml.kernel.org/r/YwNold0GMOappUxc@slm.duckdns.org > > > > So, I don't really think this is an interface we wanna go for. I was hoping > > to hear more from memcg folks in the above thread. Maybe ping them in that > > thread and continue there? > > Ah, another thing. If the memcg accounting is breaking things right now, we > can easily introduce a memcg disable flag for bpf memory. That should help > alleviating the immediate breakage while we figure this out. Hmm. We discussed this option already. We definitely don't want to introduce an uapi knob that will allow anyone to skip memcg accounting today and in the future.