Re: [PATCH] mm: workingset: account MGLRU pages in count_shadow_nodes()
From: Shakeel Butt
Date: Mon Aug 24 2026 - 12:57:55 EST
On Mon, Aug 24, 2026 at 05:16:30PM +0800, Hui Zhu wrote:
> From: Hui Zhu <zhuhui@xxxxxxxxxx>
>
> Commit 7404bd37cfbe ("mm: workingset: use lruvec_lru_size() to get the
> number of lru pages") switched count_shadow_nodes() to
> lruvec_lru_size().
Instead of adding more complexity and increasing divergence between classic LRU
and MGLRU, let's fix lruvec_page_state_local for all. Usage of lruvec_lru_size
instead lruvec_page_state_local was mainly due to concern on adding upward tree
traversal on stats update side i.e. get_non_dying_memcg_[start|end].
However offlining should be rate. Let's just use get_non_dying_memcg_[start|end]
everywhere and not just v1 and measure the impact.
Shakeel