Message ID | 20250124073514.2375622-1-chenridong@huaweicloud.com (mailing list archive) |
---|---|
Headers | show
Return-Path: <owner-linux-mm@kvack.org> 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 AFB23C02181 for <linux-mm@archiver.kernel.org>; Fri, 24 Jan 2025 07:46:17 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 2737B28003C; Fri, 24 Jan 2025 02:46:17 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 1D68D28002E; Fri, 24 Jan 2025 02:46:17 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id EF3BE28003C; Fri, 24 Jan 2025 02:46:16 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0011.hostedemail.com [216.40.44.11]) by kanga.kvack.org (Postfix) with ESMTP id C8558280039 for <linux-mm@kvack.org>; Fri, 24 Jan 2025 02:46:16 -0500 (EST) Received: from smtpin26.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay05.hostedemail.com (Postfix) with ESMTP id 70F0D45A7E for <linux-mm@kvack.org>; Fri, 24 Jan 2025 07:46:16 +0000 (UTC) X-FDA: 83041562352.26.9CA548D Received: from dggsgout11.his.huawei.com (dggsgout11.his.huawei.com [45.249.212.51]) by imf08.hostedemail.com (Postfix) with ESMTP id 1CB47160002 for <linux-mm@kvack.org>; Fri, 24 Jan 2025 07:46:13 +0000 (UTC) Authentication-Results: imf08.hostedemail.com; dkim=none; spf=none (imf08.hostedemail.com: domain of chenridong@huaweicloud.com has no SPF policy when checking 45.249.212.51) smtp.mailfrom=chenridong@huaweicloud.com; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1737704774; 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-transfer-encoding:content-transfer-encoding: in-reply-to:references; bh=5l8GEcUBT9FVxeHCt75bHSl6OPrKeQWRe+fmk8CJCMs=; b=DZJ6z7V9vOVIdrMyHqfPEf/Ie8OBOBKf3v5LIUCDjonHgVwwXebwmJugnGY/k0zwmjCvYo IK7Rl2n02CXOINR+w8L25nRfeCXnc/r33+AaHbjEMH8NwOuo03l5SnfLR2bEn/sDpFfonF Rv0DnIDPW4e7KmspZ2CMveDLhoXdPHo= ARC-Authentication-Results: i=1; imf08.hostedemail.com; dkim=none; spf=none (imf08.hostedemail.com: domain of chenridong@huaweicloud.com has no SPF policy when checking 45.249.212.51) smtp.mailfrom=chenridong@huaweicloud.com; dmarc=none ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1737704774; a=rsa-sha256; cv=none; b=8JnYp4Ym9mYFmQDIg6JZPJatogVvksBExLzbWXWOjIqH+wScuI9yACj/TrwqaRjPd4RGFv T+htWYcmnBz6epCdjfqi59IIg6xVXoITofoWKKWmad1+tWqlOT6JsPIbWI0EjS7mM/MIbP RIG0v/XmCmrj3muXhItkBPzS3xBLhUU= Received: from mail.maildlp.com (unknown [172.19.163.216]) by dggsgout11.his.huawei.com (SkyGuard) with ESMTP id 4YfVH535WCz4f3jqr for <linux-mm@kvack.org>; Fri, 24 Jan 2025 15:45:53 +0800 (CST) Received: from mail02.huawei.com (unknown [10.116.40.112]) by mail.maildlp.com (Postfix) with ESMTP id E3FB51A08DC for <linux-mm@kvack.org>; Fri, 24 Jan 2025 15:46:08 +0800 (CST) Received: from hulk-vt.huawei.com (unknown [10.67.174.121]) by APP1 (Coremail) with SMTP id cCh0CgBHqnozRZNn89xFBw--.58969S2; Fri, 24 Jan 2025 15:46:08 +0800 (CST) From: Chen Ridong <chenridong@huaweicloud.com> To: akpm@linux-foundation.org, mhocko@kernel.org, hannes@cmpxchg.org, yosryahmed@google.com, roman.gushchin@linux.dev, shakeel.butt@linux.dev, muchun.song@linux.dev, davidf@vimeo.com, vbabka@suse.cz, mkoutny@suse.com Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, cgroups@vger.kernel.org, chenridong@huawei.com, wangweiyang2@huawei.com Subject: [PATCH -v4 next 0/4] Some cleanup for memcg Date: Fri, 24 Jan 2025 07:35:10 +0000 Message-Id: <20250124073514.2375622-1-chenridong@huaweicloud.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-CM-TRANSID: cCh0CgBHqnozRZNn89xFBw--.58969S2 X-Coremail-Antispam: 1UD129KBjvdXoWruF43XrWDKFW7tryUZF18Xwb_yoWDuFg_KF Z7ZFy7Kw1jgFWUXFW2kr48JFW2kw45Zry5GF1jqr43ta43tw1qvFsrWrWrZr1rZwsIkF45 Ary5J397CwnFyjkaLaAFLSUrUUUUjb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUIcSsGvfJTRUUUbxAYFVCjjxCrM7AC8VAFwI0_Gr0_Xr1l1xkIjI8I6I8E6xAIw20E Y4v20xvaj40_Wr0E3s1l1IIY67AEw4v_Jr0_Jr4l8cAvFVAK0II2c7xJM28CjxkF64kEwV A0rcxSw2x7M28EF7xvwVC0I7IYx2IY67AKxVW7JVWDJwA2z4x0Y4vE2Ix0cI8IcVCY1x02 67AKxVWxJVW8Jr1l84ACjcxK6I8E87Iv67AKxVW0oVCq3wA2z4x0Y4vEx4A2jsIEc7CjxV AFwI0_GcCE3s1le2I262IYc4CY6c8Ij28IcVAaY2xG8wAqx4xG64xvF2IEw4CE5I8CrVC2 j2WlYx0E2Ix0cI8IcVAFwI0_JrI_JrylYx0Ex4A2jsIE14v26r1j6r4UMcvjeVCFs4IE7x kEbVWUJVW8JwACjcxG0xvY0x0EwIxGrwACI402YVCY1x02628vn2kIc2xKxwCY1x0262kK e7AKxVWUtVW8ZwCF04k20xvY0x0EwIxGrwCFx2IqxVCFs4IE7xkEbVWUJVW8JwC20s026c 02F40E14v26r1j6r18MI8I3I0E7480Y4vE14v26r106r1rMI8E67AF67kF1VAFwI0_Jw0_ GFylIxkGc2Ij64vIr41lIxAIcVC0I7IYx2IY67AKxVWUJVWUCwCI42IY6xIIjxv20xvEc7 CjxVAFwI0_Gr0_Cr1lIxAIcVCF04k26cxKx2IYs7xG6r1j6r1xMIIF0xvEx4A2jsIE14v2 6r1j6r4UMIIF0xvEx4A2jsIEc7CjxVAFwI0_Gr0_Gr1UYxBIdaVFxhVjvjDU0xZFpf9x07 UQ6p9UUUUU= X-CM-SenderInfo: hfkh02xlgr0w46kxt4xhlfz01xgou0bp/ X-Rspam-User: X-Rspamd-Server: rspam09 X-Rspamd-Queue-Id: 1CB47160002 X-Stat-Signature: sn4fbzmznimbfnadbxu3hnmfh34k85on X-HE-Tag: 1737704773-985925 X-HE-Meta: U2FsdGVkX1+IE4PSRK5dBh7Lqn+iDXqcUbpM8PeKnV4jQaEZFEhE09LYE+ayXME07gLTjp7bVqr8/mWWH8Ad+c7bQViXFHSqBOSsUoja73WxGBvW/q27pig8TFtJAHRn9c/5BaXS6z+FLPjMQGzg8J7e0JmVwzYOURxwnJZVlhUcY6r5CgMgx8xzoq+iN0ybsxGQ+NqGIZu75aFRcogqNFhAg7OpYfRWnsy/RJL/KlgCusTx7h9vd8IaPnGcB5ox1xMZ+E8sMAF1VifTcB42BkomowUnFV47G11WhP2i34UyEqz+Zbrs/aNFzj6cFPlc15WxDSDfWnOD8yZDHLFCBP50wupZA3jzIsW9wbwzJFepYUe4qLFDFrk4mrY/S/knSkzsmSK99C5k4suVX/yPqGUrZl3SavANPy6idBl9VBaetTiOVAz3iKjRFG54hufDLX5IXuEU5BpjUa9yFYWRRTgqqoNdWSMgvMwYIQppUMa9AiV7Z4NOOwFGcPsPyHy2wO8jnq+URBiWk+Qh5y6s/pelr8WR5+xlulBb+ri70WRJbgobaUu1f1NPJMi2qtvog8oAtl5AUf6GQK56L/+rGZEWqglE0IVsD4JRH2vuon5ztt2PQeJDIqxuFbmAD8yXRnflxyNJVQEib0IQRQhgoBrt8ycdDygQxaxqU6YMO7nSyu9vuRo9AkD+RY/GKD2UJMP8liEyaMc5sXJvmnNi29kMhDZmSSfjAxhfsOtitIoQP67L5MdT9ToGWvdmWVrNvtTRuUHQaMdstfTBVuk0bXo0QM0QjP43ScAgNULBx0lgHlY2qFcEIGyZmqaNJecVuGdxMuPrW8Y7Dewr8TU76DZ29OscKZulV71gkj5EvDH8iMTYGL0ckLoS2myI7zwDugYaRsiKMYPHxOwOuuRjZzpUuPAz8F7ppBk7f6IbJExglGeoR63XPo7uYk1RaYAQ8s8D6SIko4AIAs5Db7T JsU3P38K R1+zujNsTM6LDuDiKQZbFjXBLY40XIFhTI9w3KIcUrn5BttA6B/nDub/yt4CdZZ0CVu9pFNLUCTUWSZxDFmoNM0cS76+PD9d7zLZCsWEM2uAVy9JG74kMyCzRP42kw0kmNjoefcjjpWo6EdvFOY+BOi9Qlg== 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: <linux-mm.kvack.org> List-Subscribe: <mailto:majordomo@kvack.org> List-Unsubscribe: <mailto:majordomo@kvack.org> |
Series | Some cleanup for memcg | expand |
From: Chen Ridong <chenridong@huawei.com> Some cleanup for memcg. In this series, patches 1-3 have been reviewed. Patch 4 is new, which adds CONFIG_MEMCG_V1 for the local functions, suggested by Johannes Weiner. --- v3->v4: - keep the 'local' functions in the memcontrol-v1.c and add CONFIG_MEMCG_V1 for them. v2->v3: - move the wrapper function definitions to header files. - add a patch to move the 'local' functions to the memcontrol-v1.c. v1->v2: - drop the patch 'simplify the mem_cgroup_update_lru_size function'. - for patch 3, rename '__refill_obj_stock' to replace_stock_objcg, and keep the 'objcg equal' check in the calling functions. Chen Ridong (4): memcg: use OFP_PEAK_UNSET instead of -1 memcg: call the free function when allocation of pn fails memcg: factor out the replace_stock_objcg function memcg: add CONFIG_MEMCG_V1 for 'local' functions mm/memcontrol-v1.h | 6 ++--- mm/memcontrol.c | 61 ++++++++++++++++++++++++++-------------------- 2 files changed, 38 insertions(+), 29 deletions(-)