From patchwork Wed Jan 2 20:05:31 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yang Shi X-Patchwork-Id: 10746671 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 55B95746 for ; Wed, 2 Jan 2019 20:06:34 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 447902785D for ; Wed, 2 Jan 2019 20:06:34 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3613728390; Wed, 2 Jan 2019 20:06:34 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE,UNPARSEABLE_RELAY autolearn=ham version=3.3.1 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C26462785D for ; Wed, 2 Jan 2019 20:06:33 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id EF1DA8E0041; Wed, 2 Jan 2019 15:06:32 -0500 (EST) Delivered-To: linux-mm-outgoing@kvack.org Received: by kanga.kvack.org (Postfix, from userid 40) id EA2DF8E0002; Wed, 2 Jan 2019 15:06:32 -0500 (EST) X-Original-To: int-list-linux-mm@kvack.org X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id D90C38E0041; Wed, 2 Jan 2019 15:06:32 -0500 (EST) X-Original-To: linux-mm@kvack.org X-Delivered-To: linux-mm@kvack.org Received: from mail-pf1-f197.google.com (mail-pf1-f197.google.com [209.85.210.197]) by kanga.kvack.org (Postfix) with ESMTP id 933598E0002 for ; Wed, 2 Jan 2019 15:06:32 -0500 (EST) Received: by mail-pf1-f197.google.com with SMTP id u20so33418772pfa.1 for ; Wed, 02 Jan 2019 12:06:32 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-original-authentication-results:x-gm-message-state:from:to:cc :subject:date:message-id:in-reply-to:references; bh=dX8xM/XxlvcrFrpForq4/DrPCdSSxMRRfWDm3qPljyI=; b=fI6Lw7Pb5rCow3X/4nBj29RWPnls6kxNiALXqnW9vSTpjNEH9cd1c2MPiZWXbUXbez o8mo8ft45jjde9NLgc1d9DJ2X5BBUkv+NchOT6BZfdRgfrwbXDYbwu7eIq/Tt5KjOlVt 0ufI9MDLhRSGwFC27hpVzbrIgce98XEZUZ3OLpkwo78FGskbjIj0HFTjykuG+YFrEo21 MKo3A1zPn+1hr3K9kUygXOGL/+jRveW/JNGOhc48dWkKmW1UVU743Dxi9svFDA6uJHvn El3kArDZAa0FAbCVETmHtxTUeJeCBgsb8RQFWQq/GPPTFfXJl8oh42RNd2ouz+AHDrpN oIJw== X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of yang.shi@linux.alibaba.com designates 47.88.44.36 as permitted sender) smtp.mailfrom=yang.shi@linux.alibaba.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alibaba.com X-Gm-Message-State: AJcUukc4so5QTmCS6YV67CsSpA39FmTBzEhC0XMXjWvKML2POKvWf0v/ gQ8M4nhi1zkr1EdT0BV1Gk+WplkR9xVFvuYcCWqQ0HOn163e29ketii/YPgutvndDmuBrxU2D2m X1te3T0f3MBsRO/MJvNv3IKEbLu4zCEEBKGk0PDY3VHI3xPUqRmF6xLfsEvPkmXggPw== X-Received: by 2002:a65:6392:: with SMTP id h18mr14910051pgv.107.1546459592252; Wed, 02 Jan 2019 12:06:32 -0800 (PST) X-Google-Smtp-Source: ALg8bN7qaYcA/WhWVd5tr6qEw66aSSJEiZue9DwZa/v52tiZnmaXMfDEkYt/RF9PQtiRDNoE/ro/ X-Received: by 2002:a65:6392:: with SMTP id h18mr14909989pgv.107.1546459591232; Wed, 02 Jan 2019 12:06:31 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1546459591; cv=none; d=google.com; s=arc-20160816; b=WgDat15Yzg3QA3mN7VqVrJtVvTirYq42u629AF0IhS1TLGjCBNWZnd6L6FsQiUV4vC JZBi+a6X9qQcItuLnzNVuCaD9qYw6p7LAQMP3QNA8izVyy7ULT6/CRZJTzqBl40K16I6 vwbZCG75/yCgA1zo0ejgyuv2um8SZ1e4RmP62akfiuyiQVBMspXVPouWXdYKvNWYjw9p SOP5x4mgPytPYa2cywuTR2z/f6hfNkTjBHEb7Koixuy1zXNC+k9s9hbfhYBsR6aO7dtS i7i2UUSSYB8P6hbAfPIiosy1SEs54k0VghY6TDQ6Fc9bssR2xv4AbuakjD1QSJMgFDfH LtsA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=references:in-reply-to:message-id:date:subject:cc:to:from; bh=dX8xM/XxlvcrFrpForq4/DrPCdSSxMRRfWDm3qPljyI=; b=DOTotkTdxR+OaKM++wzGHryKSZErVS1I0kjlwJg8kqLGlQv386xpFGuBAuLf5ATT7w xOY5ofwxXqJsN5OqikNHuKfurtjQ4I6QZRTdbNKPzutILkRoBPgKa2S6McONjYfHaP9x 3m0Ai9SususoLayHBoIj/mn01nS5NIbSifyHZbBA36LWJqywAmjvrTTN+/OhPtfcrTI+ uiPUJh7JskjaE+Y/NxN0GhZ3qLRZtgT3mkD6JSxLVaGfxjn6HqA18W8OYZPf8hnhhOCl 6OQO8yXjnIkZJVU8dcR8QqW8gnpEV5tVOWb0G5eCm7D7qhCzDHUHmyvw9LWJDa/Ny/Sd YNow== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of yang.shi@linux.alibaba.com designates 47.88.44.36 as permitted sender) smtp.mailfrom=yang.shi@linux.alibaba.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: from out4436.biz.mail.alibaba.com (out4436.biz.mail.alibaba.com. [47.88.44.36]) by mx.google.com with ESMTPS id b9si48038295pgt.293.2019.01.02.12.06.29 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 02 Jan 2019 12:06:31 -0800 (PST) Received-SPF: pass (google.com: domain of yang.shi@linux.alibaba.com designates 47.88.44.36 as permitted sender) client-ip=47.88.44.36; Authentication-Results: mx.google.com; spf=pass (google.com: domain of yang.shi@linux.alibaba.com designates 47.88.44.36 as permitted sender) smtp.mailfrom=yang.shi@linux.alibaba.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alibaba.com X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R661e4;CH=green;FP=0|-1|-1|-1|0|-1|-1|-1;HT=e01e07487;MF=yang.shi@linux.alibaba.com;NM=1;PH=DS;RN=6;SR=0;TI=SMTPD_---0THOz2-._1546459534; Received: from e19h19392.et15sqa.tbsite.net(mailfrom:yang.shi@linux.alibaba.com fp:SMTPD_---0THOz2-._1546459534) by smtp.aliyun-inc.com(127.0.0.1); Thu, 03 Jan 2019 04:05:41 +0800 From: Yang Shi To: mhocko@suse.com, hannes@cmpxchg.org, akpm@linux-foundation.org Cc: yang.shi@linux.alibaba.com, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: [PATCH 1/3] doc: memcontrol: fix the obsolete content about force empty Date: Thu, 3 Jan 2019 04:05:31 +0800 Message-Id: <1546459533-36247-2-git-send-email-yang.shi@linux.alibaba.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1546459533-36247-1-git-send-email-yang.shi@linux.alibaba.com> References: <1546459533-36247-1-git-send-email-yang.shi@linux.alibaba.com> 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: X-Virus-Scanned: ClamAV using ClamSMTP We don't do page cache reparent anymore when offlining memcg, so update force empty related content accordingly. Cc: Michal Hocko Cc: Johannes Weiner Signed-off-by: Yang Shi Reviewed-by: Shakeel Butt Acked-by: Michal Hocko --- Documentation/cgroup-v1/memory.txt | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Documentation/cgroup-v1/memory.txt b/Documentation/cgroup-v1/memory.txt index 3682e99..8e2cb1d 100644 --- a/Documentation/cgroup-v1/memory.txt +++ b/Documentation/cgroup-v1/memory.txt @@ -70,7 +70,7 @@ Brief summary of control files. memory.soft_limit_in_bytes # set/show soft limit of memory usage memory.stat # show various statistics memory.use_hierarchy # set/show hierarchical account enabled - memory.force_empty # trigger forced move charge to parent + memory.force_empty # trigger forced page reclaim memory.pressure_level # set memory pressure notifications memory.swappiness # set/show swappiness parameter of vmscan (See sysctl's vm.swappiness) @@ -459,8 +459,9 @@ About use_hierarchy, see Section 6. the cgroup will be reclaimed and as many pages reclaimed as possible. The typical use case for this interface is before calling rmdir(). - Because rmdir() moves all pages to parent, some out-of-use page caches can be - moved to the parent. If you want to avoid that, force_empty will be useful. + Though rmdir() offlines memcg, but the memcg may still stay there due to + charged file caches. Some out-of-use page caches may keep charged until + memory pressure happens. If you want to avoid that, force_empty will be useful. Also, note that when memory.kmem.limit_in_bytes is set the charges due to kernel pages will still be seen. This is not considered a failure and the