DAX support in virtiofsd
Jeremy Bongio <[email protected]> Tue, 19 Aug 2025 14:13:31 -0700
| Newsgroups | dev.linux.lists.virtio-fs |
|---|---|
| Message-ID | <CAOvQCn5H3Xpn3RJbMyE6=BkcbgBPrjap6mDbRYJ3wayiV_yGGA@mail.gmail.com> |
Hello, My team has been using DAX w/ virtiofsd for read-only devices. We are interested in continuing this use case, but support has been removed upstream for * setup/remove mapping in vhost-user rust crate. https://github.com/rust-vmm/vhost/commit/569ef077facafe21f16c0e65ff826b26d3c9a0b3 discussion: https://github.com/rust-vmm/vhost/issues/213 * as a consequence, setupmapping/removemapping in virtiofsd. https://gitlab.com/virtio-fs/virtiofsd/-/commit/87f67e84cb032e6f4ce4a9f408b6305f33d2d041 The virtio spec already/still contains support for DAX. The primary reasons for removing support for this feature in vhost and virtiofsd appear to be that it is not in the vhost-user spec (https://www.qemu.org/docs/master/interop/vhost-user.html) and there are major edge cases not dealt with, so DAX can't be safely used if the backing store can change in size. Some of the major technical challenges to supporting DAX were discussed in: https://lore.kernel.org/virtio-fs/[email protected]/ ... Specifically: > 1. How to inject SIGBUS when the guest accesses a page that's beyond > the end-of-file. > 2. Implementing the vhost-user messages for mapping ranges of files to > the vhost-user frontend. I expect the steps to support DAX in virtiofsd are: 1. add the necessary vhost-user messages for mapping ranges to the spec ... What is the RFC process for modifying the vhost standard? What mailing list should I use? 2. re-implement vhost-user messages in the vhost-user rust crate 3. re-implement setup/remove mapping in virtiofsd. 4. implement new vhost-user messages in qemu? 5. find solution for safely handling page faults beyond EOF. Can you offer comments, guidance, opinions? Is there resistance to this work or is it that no one was interested enough to complete it?