[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <924f57a8-deaa-4f7d-93ee-4030e2445a01@cdn77.com>
Date: Thu, 17 Jul 2025 17:31:07 +0200
From: Daniel Sedlak <daniel.sedlak@...77.com>
To: Kuniyuki Iwashima <kuniyu@...gle.com>,
Shakeel Butt <shakeel.butt@...ux.dev>
Cc: "David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>, Jakub Kicinski <kuba@...nel.org>,
Paolo Abeni <pabeni@...hat.com>, Simon Horman <horms@...nel.org>,
Jonathan Corbet <corbet@....net>, Neal Cardwell <ncardwell@...gle.com>,
David Ahern <dsahern@...nel.org>, Andrew Morton <akpm@...ux-foundation.org>,
Yosry Ahmed <yosry.ahmed@...ux.dev>, linux-mm@...ck.org,
netdev@...r.kernel.org, Matyas Hurtik <matyas.hurtik@...77.com>
Subject: Re: [PATCH v2 net-next 1/2] tcp: account for memory pressure signaled
by cgroup
On 7/16/25 8:07 PM, Kuniyuki Iwashima wrote:
>> Incrementing it here will give a very different semantic to this stat
>> compared to LINUX_MIB_TCPMEMORYPRESSURES. Here the increments mean the
>> number of times the kernel check if a given socket is under memcg
>> pressure for a net namespace. Is that what we want?
>
> I'm trying to decouple sk_memcg from the global tcp_memory_allocated
> as you and Wei planned before, and the two accounting already have the
> different semantics from day1 and will keep that, so a new stat having a
> different semantics would be fine.
>
> But I think per-memcg stat like memory.stat.XXX would be a good fit
> rather than pre-netns because one netns could be shared by multiple
> cgroups and multiple sockets in the same cgroup could be spread across
> multiple netns.
I can move the counter to memory.stat.XXX in favor of this patch, if
anyone has not started working on that yet?
Or are you suggesting to keep this change and also add it to the
memory.stat.XXX?
Thanks!
Daniel
Powered by blists - more mailing lists