c4af8b173a
At least prior to 7.23 (which adds FUSE_WRITEBACK_CACHE), the FUSE protocol specifies only clean data to be cached. Prior to this change, we implement and default to writeback caching. This is ok enough for local only filesystems without hardlinks, but violates the general design contract with FUSE and breaks distributed filesystems or concurrent access to hardlinks of the same inode. In this change, add cache mode as an extension of cache enable/disable. The new modes are UC (was: cache disabled), WT (default), and WB (was: cache enabled). For now, WT caching is implemented as write-around, which meets the goal of only caching clean data. WT can be better than WA for workloads that frequently read data that was recently written, but WA is trivial to implement. Note that this has no effect on O_WRONLY-opened files, which were already coerced to write-around. Refs: * https://sourceforge.net/p/fuse/mailman/message/8902254/ * https://github.com/vgough/encfs/issues/315 PR: 230258 (inspired by) |
||
---|---|---|
.. | ||
fuse_debug.h | ||
fuse_device.c | ||
fuse_file.c | ||
fuse_file.h | ||
fuse_internal.c | ||
fuse_internal.h | ||
fuse_io.c | ||
fuse_io.h | ||
fuse_ipc.c | ||
fuse_ipc.h | ||
fuse_kernel.h | ||
fuse_main.c | ||
fuse_node.c | ||
fuse_node.h | ||
fuse_param.h | ||
fuse_vfsops.c | ||
fuse_vnops.c | ||
fuse.h |