The patch titled Subject: Documentation/admin-guide/cgroup-v2.rst: document why inactive_X + active_X may not equal X has been added to the -mm tree. Its filename is docs-cgroup-mm-document-why-inactive_x-active_x-may-not-equal-x.patch This patch should soon appear at http://ozlabs.org/~akpm/mmots/broken-out/docs-cgroup-mm-document-why-inactive_x-active_x-may-not-equal-x.patch and later at http://ozlabs.org/~akpm/mmotm/broken-out/docs-cgroup-mm-document-why-inactive_x-active_x-may-not-equal-x.patch Before you just go and hit "reply", please: a) Consider who else should be cc'ed b) Prefer to cc a suitable mailing list as well c) Ideally: find the original patch on the mailing list and do a reply-to-all to that, adding suitable additional cc's *** Remember to use Documentation/process/submit-checklist.rst when testing your code *** The -mm tree is included into linux-next and is updated there every 3-4 working days ------------------------------------------------------ From: Chris Down <chris@xxxxxxxxxxxxxx> Subject: Documentation/admin-guide/cgroup-v2.rst: document why inactive_X + active_X may not equal X This has confused a significant number of people using cgroups inside Facebook, and some of those outside as well judging by posts like this[0] (although it's not a problem unique to cgroup v2). If shmem handling in particular becomes more coherent at some point in the future -- although that seems unlikely now -- we can change the wording here. [0]: https://unix.stackexchange.com/q/525092/10762 Link: http://lkml.kernel.org/r/20191111144958.GA11914@xxxxxxxxxxxxxx Signed-off-by: Chris Down <chris@xxxxxxxxxxxxxx> Acked-by: Michal Hocko <mhocko@xxxxxxxx> Cc: Johannes Weiner <hannes@xxxxxxxxxxx> Cc: Tejun Heo <tj@xxxxxxxxxx> Cc: Roman Gushchin <guro@xxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- Documentation/admin-guide/cgroup-v2.rst | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) --- a/Documentation/admin-guide/cgroup-v2.rst~docs-cgroup-mm-document-why-inactive_x-active_x-may-not-equal-x +++ a/Documentation/admin-guide/cgroup-v2.rst @@ -1288,7 +1288,12 @@ PAGE_SIZE multiple when read back. inactive_anon, active_anon, inactive_file, active_file, unevictable Amount of memory, swap-backed and filesystem-backed, on the internal memory management lists used by the - page reclaim algorithm + page reclaim algorithm. + + As these represent internal list state (eg. shmem pages are on anon + memory management lists), inactive_foo + active_foo may not be equal to + the value for the foo counter, since the foo counter is type-based, not + list-based. slab_reclaimable Part of "slab" that might be reclaimed, such as _ Patches currently in -mm which might be from chris@xxxxxxxxxxxxxx are docs-cgroup-mm-document-why-inactive_x-active_x-may-not-equal-x.patch