On Tue, Mar 28, 2023 at 12:59:55PM -0700, Yosry Ahmed wrote: > > So it wouldn't be my first preference. But it sounds workable. > > If we settle on this as a first step, perhaps to avoid any ABI changes Turn on zswap without a real swapfile is user space visible change. Some small change is unavoidable, ABI or not. > we can have the kernel create a virtual swap device for zswap if it is > enabled, without userspace interfering or having to do swapon on a > sparse swapfile like we do today with ghost swapfiles at Google. We > can then implement indirection logic that only supports moving pages > between swap devices -- and perhaps only restrict it to only support > the virtual zswap swap device as a top tier initially. One more things to consider is that, Google use more than one ghost swapfiles for zswap due to scalability. There might be scalability implication if there can be only one zswap device. Chris