Linux-mm Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/4] mm: zswap: misc optimizations
@ 2026-09-10  9:54 Kefeng Wang
  2026-09-10  9:54 ` [PATCH v2 1/4] mm: zswap: pass type and offset to zswap_invalidate() directly Kefeng Wang
                   ` (3 more replies)
  0 siblings, 4 replies; 14+ messages in thread
From: Kefeng Wang @ 2026-09-10  9:54 UTC (permalink / raw)
  To: Andrew Morton
  Cc: linux-mm, Chengming Zhou, Johannes Weiner, Kairui Song, Nhat Pham,
	Yosry Ahmed, Kefeng Wang

This series cleans up duplication in zswap_invalidate() and adds
fast paths in zswap_store() which now skips redundant xarray lookups,
while swap_range_free() skips needless zswap_invalidate() calls.

v2:
- split patches and refactor zswap_invalidate(), suggested by
  Johannes Weiner
- add patch4 to skip zswap_invalidate() in swap_range_free()

Kefeng Wang (4):
  mm: zswap: pass type and offset to zswap_invalidate() directly
  mm: zswap: reuse zswap_invalidate() in zswap_store() check_old path
  mm: zswap: avoid unnecessary xarray lookup in zswap_store()
  mm: zswap: skip zswap_invalidate() in swap_range_free() when zswap is
    unused

 include/linux/zswap.h |  4 ++--
 mm/swapfile.c         |  6 ++++--
 mm/zswap.c            | 29 +++++++++++++++--------------
 3 files changed, 21 insertions(+), 18 deletions(-)

-- 
2.55.0



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

end of thread, other threads:[~2026-09-10 19:28 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-10  9:54 [PATCH v2 0/4] mm: zswap: misc optimizations Kefeng Wang
2026-09-10  9:54 ` [PATCH v2 1/4] mm: zswap: pass type and offset to zswap_invalidate() directly Kefeng Wang
2026-09-10 10:26   ` Yosry Ahmed
2026-09-10 17:57   ` Nhat Pham
2026-09-10 19:27   ` Johannes Weiner
2026-09-10  9:54 ` [PATCH v2 2/4] mm: zswap: reuse zswap_invalidate() in zswap_store() check_old path Kefeng Wang
2026-09-10 10:27   ` Yosry Ahmed
2026-09-10 19:27   ` Johannes Weiner
2026-09-10  9:54 ` [PATCH v2 3/4] mm: zswap: avoid unnecessary xarray lookup in zswap_store() Kefeng Wang
2026-09-10 10:28   ` Yosry Ahmed
2026-09-10  9:54 ` [PATCH v2 4/4] mm: zswap: skip zswap_invalidate() in swap_range_free() when zswap is unused Kefeng Wang
2026-09-10 10:29   ` Yosry Ahmed
2026-09-10 11:10     ` Kefeng Wang
2026-09-10 11:12       ` Yosry Ahmed

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