linux-doc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jonathan Corbet <corbet@lwn.net>
To: "Michal Koutný" <mkoutny@suse.com>,
	cgroups@vger.kernel.org, linux-doc@vger.kernel.org,
	linux-kernel@vger.kernel.org
Cc: "Natalie Vock" <natalie.vock@gmx.de>,
	"Maarten Lankhorst" <dev@lankhorst.se>,
	"Michal Koutný" <mkoutny@suse.com>, "Tejun Heo" <tj@kernel.org>,
	"Johannes Weiner" <hannes@cmpxchg.org>
Subject: Re: [PATCH RESEND 1/3] docs: cgroup: Explain reclaim protection target
Date: Mon, 10 Nov 2025 13:00:41 -0700	[thread overview]
Message-ID: <87wm3xwtcm.fsf@trenco.lwn.net> (raw)
In-Reply-To: <20251110193638.623208-2-mkoutny@suse.com>

Michal Koutný <mkoutny@suse.com> writes:

> The protection target is necessary to understand how effective reclaim
> protection applies in the hierarchy.
>
> Signed-off-by: Michal Koutný <mkoutny@suse.com>
> ---
>  Documentation/admin-guide/cgroup-v2.rst | 24 +++++++++++++++++++++---
>  1 file changed, 21 insertions(+), 3 deletions(-)
>
> diff --git a/Documentation/admin-guide/cgroup-v2.rst b/Documentation/admin-guide/cgroup-v2.rst
> index 0e6c67ac585a0..a6def773a3072 100644
> --- a/Documentation/admin-guide/cgroup-v2.rst
> +++ b/Documentation/admin-guide/cgroup-v2.rst
> @@ -53,7 +53,8 @@ v1 is available under :ref:`Documentation/admin-guide/cgroup-v1/index.rst <cgrou
>       5-2. Memory
>         5-2-1. Memory Interface Files
>         5-2-2. Usage Guidelines
> -       5-2-3. Memory Ownership
> +       5-2-3. Reclaim Protection
> +       5-2-4. Memory Ownership

I always have to ask...do we really need the manually maintained TOC
here? 

>       5-3. IO
>         5-3-1. IO Interface Files
>         5-3-2. Writeback
> @@ -1317,7 +1318,7 @@ PAGE_SIZE multiple when read back.
>  	smaller overages.
>  
>  	Effective min boundary is limited by memory.min values of
> -	all ancestor cgroups. If there is memory.min overcommitment
> +	ancestor cgroups. If there is memory.min overcommitment
>  	(child cgroup or cgroups are requiring more protected memory
>  	than parent will allow), then each child cgroup will get
>  	the part of parent's protection proportional to its
> @@ -1343,7 +1344,7 @@ PAGE_SIZE multiple when read back.
>  	smaller overages.
>  
>  	Effective low boundary is limited by memory.low values of
> -	all ancestor cgroups. If there is memory.low overcommitment
> +	ancestor cgroups. If there is memory.low overcommitment
>  	(child cgroup or cgroups are requiring more protected memory
>  	than parent will allow), then each child cgroup will get
>  	the part of parent's protection proportional to its
> @@ -1934,6 +1935,23 @@ memory - is necessary to determine whether a workload needs more
>  memory; unfortunately, memory pressure monitoring mechanism isn't
>  implemented yet.
>  
> +Reclaim Protection
> +~~~~~~~~~~~~~~~~~~
> +
> +The protection configured with "memory.low" or "memory.min" applies relatively
> +to the target of the reclaim (i.e. any of memory cgroup limits, proactive
> +memory.reclaim or global reclaim apparently located in the root cgroup).
> +
> +  root ... - A - B - C
> +              \    ` D
> +               ` E

This will not render properly, you want it in a literal block.  The
easiest way is to just make the line above read:

   ...located in the root cgroup)::

Thanks,

jon

  reply	other threads:[~2025-11-10 20:00 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-10 19:36 [PATCH RESEND 0/3] Memory reclaim documentation fixes Michal Koutný
2025-11-10 19:36 ` [PATCH RESEND 1/3] docs: cgroup: Explain reclaim protection target Michal Koutný
2025-11-10 20:00   ` Jonathan Corbet [this message]
2025-11-14 18:29     ` Michal Koutný
2025-11-14 21:11       ` Tejun Heo
2025-11-10 19:36 ` [PATCH RESEND 2/3] docs: cgroup: Note about sibling relative reclaim protection Michal Koutný
2025-11-10 19:36 ` [PATCH RESEND 3/3] docs: cgroup: No special handling of unpopulated memcgs Michal Koutný

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87wm3xwtcm.fsf@trenco.lwn.net \
    --to=corbet@lwn.net \
    --cc=cgroups@vger.kernel.org \
    --cc=dev@lankhorst.se \
    --cc=hannes@cmpxchg.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mkoutny@suse.com \
    --cc=natalie.vock@gmx.de \
    --cc=tj@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).