Re: [f2fs-dev] [PATCH v2 19/20] f2fs: count compress cache entries in pages for its memory limit

From: Chao Yu

Date: Tue Nov 17 2026 - 21:30:39 EST


On 11/16/26 12:08, Daeho Jeong wrote:
> From: Daeho Jeong <daehojeong@xxxxxxxxxx>
>
> The compress cache holds one filesystem block per entry, but
> f2fs_available_free_memory() compares the number of entries with a
> percentage of free memory counted in pages. With subpage blocks, this
> limits the compress cache to a fraction (block size / PAGE_SIZE) of
> the memory that compress_percent allows. Convert the entry count to
> pages before the comparison.
>
> No functional change when the block size equals PAGE_SIZE.
>
> Signed-off-by: Daeho Jeong <daehojeong@xxxxxxxxxx>
Reviewed-by: Chao Yu <chao@xxxxxxxxxx>

Thanks,