Re: [PATCH RFC 12/15] mm, swap: merge zeromap into swap table
From: Kairui Song
Date: Thu Feb 26 2026 - 00:49:52 EST
Barry Song <21cnbao@xxxxxxxxx> 于 2026年2月26日周四 05:40写道:
> I did notice that some cache data has been consolidated from two
> places—the swap table and the zeromap—into a single location.
> However, swap_zeromap_batch() previously operated on a bitmap,
> whereas it now accesses multiple data. Is that also
> expected to be fine?
Yeah, should be totally fine. The only two callers are:
__swap_cache_check_batch, right before looping the swap table as I
just mentioned and can be inlined to reduce overhead.
Another one is swap_read_folio_zeromap, also should be right after
adding the folio into swap table.