On 2017-05-24 19:05, Kai Krakow wrote: > To get in line with Rich Freeman: I didn't want to imply that zswap > only works with swap, neither that tmpfs only works with swap. Both > work without. But if you want to put some serious amount of data into > tmpfs, you need swap as a backing device sooner or later.
Looking at zswap, I have several questions (even after reading linux/Documentation/vm/zswap.txt). 1. How does it know which swap device to use as backing store, if any? Clearly at boot time no swap configuration exists, even if initrd/initramfs is used, which here it is not. So when the kernel sees zswap.enable=1 in the command line, what happens? 2. The doc says it can be turned on at runtime by means of /sys/module/zswap/parameters/enabled. But kconfig doesn't make it possible to build the support as a module, only built-in, and so it is not surprising that this path doesn't exist. 3. It seems to require zbud to also be turned on, but this is not enforced by kconfig. Is this a bug or what? 4. Quoting: Zswap seeks to be simple in its policies. Sysfs attributes allow for one user controlled policy: * max_pool_percent - The maximum percentage of memory that the compressed pool can occupy. Does this mean this is another (hypothetical) node in /sys/module/zswap/parameters/ ? -- Please *no* private Cc: on mailing lists and newsgroups Personal signed mail: please _encrypt_ and sign Don't clear-text sign: http://primate.net/~itz/blog/the-problem-with-gpg-signatures.html