linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/2] mm: zswap: add per-memcg stat for incompressible pages
@ 2026-02-06  7:22 Jiayuan Chen
  2026-02-06  7:22 ` [PATCH v2 1/2] " Jiayuan Chen
  2026-02-06  7:22 ` [PATCH v2 2/2] selftests/cgroup: add test for zswap " Jiayuan Chen
  0 siblings, 2 replies; 11+ messages in thread
From: Jiayuan Chen @ 2026-02-06  7:22 UTC (permalink / raw)
  To: linux-mm
  Cc: Jiayuan Chen, Tejun Heo, Johannes Weiner, Michal Koutný,
	Jonathan Corbet, Michal Hocko, Roman Gushchin, Shakeel Butt,
	Muchun Song, Andrew Morton, Yosry Ahmed, Nhat Pham,
	Chengming Zhou, Shuah Khan, cgroups, linux-doc, linux-kernel,
	linux-kselftest

In containerized environments, knowing which cgroup is contributing
incompressible pages to zswap is essential for effective resource
management. This series adds a new per-memcg stat 'zswap_incomp' to
track incompressible pages, along with a selftest.

Patch 1: Add the per-memcg zswap_incomp stat and documentation
Patch 2: Add selftest for the new stat

Changes v1 -> v2:
https://lore.kernel.org/linux-mm/20260205053013.25134-1-jiayuan.chen@linux.dev/

- Rename zswpraw/MEMCG_ZSWAP_RAW to zswap_incomp/MEMCG_ZSWAP_INCOMP
  (Shakeel Butt, Yosry Ahmed)
- Drop zswap_is_incomp() helper, keep opencode (size == PAGE_SIZE) with
  comments explaining the incompressibility check (Yosry Ahmed)
- Add documentation in cgroup-v2.rst (Nhat Pham, SeongJae Park)
- Add selftest as a separate patch (Nhat Pham)
- Add reference link to Chris Li's discussion on the need for per-memcg
  incompressible page tracking (Nhat Pham)

Jiayuan Chen (2):
  mm: zswap: add per-memcg stat for incompressible pages
  selftests/cgroup: add test for zswap incompressible pages

 Documentation/admin-guide/cgroup-v2.rst     |  5 ++
 include/linux/memcontrol.h                  |  1 +
 mm/memcontrol.c                             |  8 ++
 tools/testing/selftests/cgroup/test_zswap.c | 96 +++++++++++++++++++++
 4 files changed, 110 insertions(+)

-- 
2.43.0



^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2026-02-09  2:21 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-02-06  7:22 [PATCH v2 0/2] mm: zswap: add per-memcg stat for incompressible pages Jiayuan Chen
2026-02-06  7:22 ` [PATCH v2 1/2] " Jiayuan Chen
2026-02-06 15:19   ` Yosry Ahmed
2026-02-06 17:52   ` Shakeel Butt
2026-02-07  1:21   ` SeongJae Park
2026-02-09  2:20   ` Chengming Zhou
2026-02-06  7:22 ` [PATCH v2 2/2] selftests/cgroup: add test for zswap " Jiayuan Chen
2026-02-06 18:13   ` Shakeel Butt
2026-02-06 22:50   ` Nhat Pham
2026-02-07  1:35   ` SeongJae Park
2026-02-08 18:49     ` JP Kobryn

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox