main/linux-lts: Feature Request: ZSWAP module
I'd like to request that the linux-lts kernel have the ZSWAP functionality enabled as an optional module, but not configured to be enabled by default. In this fashion, people can opt-in to using it with grub commandline options without it changing the default behavior for any of our users.
This looks to have been last discussed in #2076 (closed), almost 8 years ago just when both ZSWAP/ZRAM were newly added to the mainline kernel.
My use-case is a entry-level laptop with 4GB RAM and 64GB eMMC storage. In such a system, RAM is at a premium, and eMMC is as well.
Routinely, my 4GB SWAP volume (made by setup-alpine during first install) will see active usage. By using ZSWAP, I am able to keep writes to eMMC minimized, while still maintaining optimal usage of both my RAM and SWAP.
My suggested parameters would be:
zswap zpool = zbud
Medium performance, but will do LRU page eviction under SWAP pressure.
zswap compressor = lzo-rle
Medium compression ratio, excellent compression/decompression performance.
Further details:
https://wiki.archlinux.org/title/Zswap
https://wiki.gentoo.org/wiki/Zswap