-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge tag 'fuse-update-4.18' of git://git.kernel.org/pub/scm/linux/ke…
…rnel/git/mszeredi/fuse Pull fuse updates from Miklos Szeredi: "The most interesting part of this update is user namespace support, mostly done by Eric Biederman. This enables safe unprivileged fuse mounts within a user namespace. There are also a couple of fixes for bugs found by syzbot and miscellaneous fixes and cleanups" * tag 'fuse-update-4.18' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse: fuse: don't keep dead fuse_conn at fuse_fill_super(). fuse: fix control dir setup and teardown fuse: fix congested state leak on aborted connections fuse: Allow fully unprivileged mounts fuse: Ensure posix acls are translated outside of init_user_ns fuse: add writeback documentation fuse: honor AT_STATX_FORCE_SYNC fuse: honor AT_STATX_DONT_SYNC fuse: Restrict allow_other to the superblock's namespace or a descendant fuse: Support fuse filesystems outside of init_user_ns fuse: Fail all requests with invalid uids or gids fuse: Remove the buggy retranslation of pids in fuse_dev_do_read fuse: return -ECONNABORTED on /dev/fuse read after abort fuse: atomic_o_trunc should truncate pagecache
- Loading branch information
Showing
11 changed files
with
209 additions
and
63 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
Fuse supports the following I/O modes: | ||
|
||
- direct-io | ||
- cached | ||
+ write-through | ||
+ writeback-cache | ||
|
||
The direct-io mode can be selected with the FOPEN_DIRECT_IO flag in the | ||
FUSE_OPEN reply. | ||
|
||
In direct-io mode the page cache is completely bypassed for reads and writes. | ||
No read-ahead takes place. Shared mmap is disabled. | ||
|
||
In cached mode reads may be satisfied from the page cache, and data may be | ||
read-ahead by the kernel to fill the cache. The cache is always kept consistent | ||
after any writes to the file. All mmap modes are supported. | ||
|
||
The cached mode has two sub modes controlling how writes are handled. The | ||
write-through mode is the default and is supported on all kernels. The | ||
writeback-cache mode may be selected by the FUSE_WRITEBACK_CACHE flag in the | ||
FUSE_INIT reply. | ||
|
||
In write-through mode each write is immediately sent to userspace as one or more | ||
WRITE requests, as well as updating any cached pages (and caching previously | ||
uncached, but fully written pages). No READ requests are ever sent for writes, | ||
so when an uncached page is partially written, the page is discarded. | ||
|
||
In writeback-cache mode (enabled by the FUSE_WRITEBACK_CACHE flag) writes go to | ||
the cache only, which means that the write(2) syscall can often complete very | ||
fast. Dirty pages are written back implicitly (background writeback or page | ||
reclaim on memory pressure) or explicitly (invoked by close(2), fsync(2) and | ||
when the last ref to the file is being released on munmap(2)). This mode | ||
assumes that all changes to the filesystem go through the FUSE kernel module | ||
(size and atime/ctime/mtime attributes are kept up-to-date by the kernel), so | ||
it's generally not suitable for network filesystems. If a partial page is | ||
written, then the page needs to be first read from userspace. This means, that | ||
even for files opened for O_WRONLY it is possible that READ requests will be | ||
generated by the kernel. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.