Hi Hao,
On 5/2/23 09:28, Hao Xu wrote:
Hi all,
From discussion with Bernd, I get that FOPEN_DIRECT_IO is designed for
those user cases where users want strong coherency like network
filesystems, where one server serves multiple remote clients. And thus
shared mmap is disabled since local page cache existence breaks this
kind of coherency.
But here our use case is one virtiofs daemon serve one guest vm, We use
FOPEN_DIRECT_IO to reduce memory footprint not for coherency. So we
expect shared mmap works in this case. Here I suggest/am implementing
adding another flag to indicate this kind of cases----use
FOPEN_DIRECT_IO not for coherency----so that shared mmap works.
Yeah it should work, but I think what you want is "DAX" - can you try to
enable it?
fuse_i.h: FUSE_DAX_ALWAYS, /* "-o dax=always" */
fuse_i.h: FUSE_DAX_NEVER, /* "-o dax=never" */
fuse_i.h: FUSE_DAX_INODE_USER, /* "-o dax=inode" */
Hope it helps,
Bernd