From patchwork Wed Sep 29 10:19:26 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Baolin Wang X-Patchwork-Id: 12525251 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 mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 64AEFC433F5 for ; Wed, 29 Sep 2021 10:20:30 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 0C7CA61246 for ; Wed, 29 Sep 2021 10:20:30 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 0C7CA61246 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linux.alibaba.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kvack.org Received: by kanga.kvack.org (Postfix) id 977246B0088; Wed, 29 Sep 2021 06:20:29 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 927136B0087; Wed, 29 Sep 2021 06:20:29 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 8152F94001B; Wed, 29 Sep 2021 06:20:29 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0009.hostedemail.com [216.40.44.9]) by kanga.kvack.org (Postfix) with ESMTP id 6A5E86B0087 for ; Wed, 29 Sep 2021 06:20:29 -0400 (EDT) Received: from smtpin02.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay02.hostedemail.com (Postfix) with ESMTP id 2CF7C2FD81 for ; Wed, 29 Sep 2021 10:20:29 +0000 (UTC) X-FDA: 78640216578.02.D88CA5F Received: from out30-43.freemail.mail.aliyun.com (out30-43.freemail.mail.aliyun.com [115.124.30.43]) by imf09.hostedemail.com (Postfix) with ESMTP id 4DEB33000108 for ; Wed, 29 Sep 2021 10:20:27 +0000 (UTC) X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R131e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=e01e04426;MF=baolin.wang@linux.alibaba.com;NM=1;PH=DS;RN=4;SR=0;TI=SMTPD_---0Uq0ghvM_1632910824; Received: from localhost(mailfrom:baolin.wang@linux.alibaba.com fp:SMTPD_---0Uq0ghvM_1632910824) by smtp.aliyun-inc.com(127.0.0.1); Wed, 29 Sep 2021 18:20:24 +0800 From: Baolin Wang To: akpm@linux-foundation.org Cc: baolin.wang@linux.alibaba.com, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: [PATCH 0/2] Support hugetlb charge moving at task migration Date: Wed, 29 Sep 2021 18:19:26 +0800 Message-Id: X-Mailer: git-send-email 1.8.3.1 X-Rspamd-Server: rspam03 X-Rspamd-Queue-Id: 4DEB33000108 X-Stat-Signature: euxj1r8rp67c8jedif54ezs89nxmqgym Authentication-Results: imf09.hostedemail.com; dkim=none; dmarc=pass (policy=none) header.from=alibaba.com; spf=pass (imf09.hostedemail.com: domain of baolin.wang@linux.alibaba.com designates 115.124.30.43 as permitted sender) smtp.mailfrom=baolin.wang@linux.alibaba.com X-HE-Tag: 1632910827-528120 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: Hi, Now in the hugetlb cgroup, charges associated with a task aren't moved to the new hugetlb cgroup at task migration, which is odd for hugetlb cgroup usage. This patch set adds hugetlb cgroup charge moving when migrate tasks among cgroups, which are based on the memcg charge moving. Please help to review. Thanks. Baolin Wang (2): hugetlb_cgroup: Add interfaces to move hugetlb charge at task migration hugetlb_cgroup: Add post_attach interface for tasks migration mm/hugetlb_cgroup.c | 230 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 230 insertions(+)