linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Wei Yang <richard.weiyang@gmail.com>
To: Michal Hocko <mhocko@suse.com>
Cc: Wei Yang <richard.weiyang@gmail.com>,
	akpm@linux-foundation.org, cgroups@vger.kernel.org,
	linux-mm@kvack.org, Roman Gushchin <roman.gushchin@linux.dev>,
	Johannes Weiner <hannes@cmpxchg.org>
Subject: Re: [PATCH] mm/memcg: non-hierarchical mode is deprecated
Date: Tue, 5 Apr 2022 02:22:18 +0000	[thread overview]
Message-ID: <20220405022218.53idmvm2ha2tzmy2@master> (raw)
In-Reply-To: <Ykq6Gbt5MX9GCiKM@dhcp22.suse.cz>

On Mon, Apr 04, 2022 at 11:27:53AM +0200, Michal Hocko wrote:
>On Sun 03-04-22 02:08:33, Wei Yang wrote:
>> After commit bef8620cd8e0 ("mm: memcg: deprecate the non-hierarchical
>> mode"), we won't have a NULL parent except root_mem_cgroup. And this
>> case is handled when (memcg == root).
>> 
>> Signed-off-by: Wei Yang <richard.weiyang@gmail.com>
>> CC: Roman Gushchin <roman.gushchin@linux.dev>
>> CC: Johannes Weiner <hannes@cmpxchg.org>
>
>Acked-by: Michal Hocko <mhocko@suse.com>
>Thanks!
>

Thanks for the ack. When reading the code, I found one redundant check in
shrink_node_memcgs().

  shrink_node_memcgs
    mem_cgroup_below_min
      mem_cgroup_supports_protection
    mem_cgroup_below_low
      mem_cgroup_supports_protection

I am not sure it worthwhile to take it out.

  shrink_node_memcgs
    mem_cgroup_supports_protection
      mem_cgroup_below_min
      mem_cgroup_below_low

Look forward your opinion.

-- 
Wei Yang
Help you, Help me


  reply	other threads:[~2022-04-05  2:22 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-03  2:08 Wei Yang
2022-04-04  9:27 ` Michal Hocko
2022-04-05  2:22   ` Wei Yang [this message]
2022-04-05  6:26     ` Michal Hocko
2022-04-05  8:05       ` Wei Yang
2022-04-04 19:11 ` Roman Gushchin
2022-04-05 18:20 ` Shakeel Butt

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=20220405022218.53idmvm2ha2tzmy2@master \
    --to=richard.weiyang@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=cgroups@vger.kernel.org \
    --cc=hannes@cmpxchg.org \
    --cc=linux-mm@kvack.org \
    --cc=mhocko@suse.com \
    --cc=roman.gushchin@linux.dev \
    /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