Re: [PATCH 2/4] memcg: separate local_trylock for memcg and obj
From: Vlastimil Babka <hidden>
Date: 2025-05-07 11:46:20
Also in:
bpf, cgroups, linux-mm, lkml
From: Vlastimil Babka <hidden>
Date: 2025-05-07 11:46:20
Also in:
bpf, cgroups, linux-mm, lkml
On 5/7/25 12:55 AM, Shakeel Butt wrote:
The per-cpu stock_lock protects cached memcg and cached objcg and their respective fields. However there is no dependency between these fields and it is better to have fine grained separate locks for cached memcg and cached objcg. This decoupling of locks allows us to make the memcg charge cache and objcg charge cache to be nmi safe independently. At the moment, memcg charge cache is already nmi safe and this decoupling will allow to make memcg charge cache work without disabling irqs. Signed-off-by: Shakeel Butt <shakeel.butt@linux.dev>
Reviewed-by: Vlastimil Babka <redacted>