Revision tags: release/14.2.0 |
|
#
f0f596bd |
| 02-Nov-2024 |
CismonX <admin@cismon.net> |
fusefs: ignore FUSE_NO_OPEN(DIR)_SUPPORT flags
The FUSE_NO_OPEN_SUPPORT and FUSE_NO_OPENDIR_SUPPORT flags are only meant to indicate kernel features, and should be ignored if they appear in the FUSE
fusefs: ignore FUSE_NO_OPEN(DIR)_SUPPORT flags
The FUSE_NO_OPEN_SUPPORT and FUSE_NO_OPENDIR_SUPPORT flags are only meant to indicate kernel features, and should be ignored if they appear in the FUSE_INIT reply flags.
Also fix the corresponding test cases.
MFC after: 2 weeks Reviewed by: Alan Somers <asomers@FreeBSD.org> Signed-off-by: CismonX <admin@cismon.net> Pull Request: https://github.com/freebsd/freebsd-src/pull/1509
show more ...
|
Revision tags: release/13.4.0, release/14.1.0, release/13.3.0, release/14.0.0 |
|
#
662ec2f7 |
| 04-Oct-2023 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: sanitize FUSE_READLINK results for embedded NULs
If VOP_READLINK returns a path that contains a NUL, it will trigger an assertion in vfs_lookup. Sanitize such paths in fusefs, rejecting any
fusefs: sanitize FUSE_READLINK results for embedded NULs
If VOP_READLINK returns a path that contains a NUL, it will trigger an assertion in vfs_lookup. Sanitize such paths in fusefs, rejecting any and warning the user about the misbehaving server.
PR: 274268 MFC after: 1 week Sponsored by: Axcient Reviewed by: mjg, markj Differential Revision: https://reviews.freebsd.org/D42081
show more ...
|
#
95ee2897 |
| 16-Aug-2023 |
Warner Losh <imp@FreeBSD.org> |
sys: Remove $FreeBSD$: two-line .h pattern
Remove /^\s*\*\n \*\s+\$FreeBSD\$$\n/
|
Revision tags: release/13.2.0, release/12.4.0, release/13.1.0 |
|
#
0bef4927 |
| 05-May-2022 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: handle evil servers that return illegal inode numbers
* If during FUSE_CREATE, FUSE_MKDIR, etc the server returns the same inode number for the new file as for its parent directory, reject
fusefs: handle evil servers that return illegal inode numbers
* If during FUSE_CREATE, FUSE_MKDIR, etc the server returns the same inode number for the new file as for its parent directory, reject it. Previously this would triggers a recurse-on-non-recursive lock panic.
* If during FUSE_LINK the server returns a different inode number for the new name as for the old one, reject it. Obviously, that can't be a hard link.
* If during FUSE_LOOKUP the server returns the same inode number for the new file as for its parent directory, reject it. Nothing good can come of this.
PR: 263662 Reported by: Robert Morris <rtm@lcs.mit.edu> MFC after: 2 weeks Reviewed by: pfg Differential Revision: https://reviews.freebsd.org/D35128
show more ...
|
Revision tags: release/12.3.0 |
|
#
7124d2bc |
| 25-Sep-2021 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: implement FUSE_NO_OPEN_SUPPORT and FUSE_NO_OPENDIR_SUPPORT
For file systems that allow it, fusefs will skip FUSE_OPEN, FUSE_RELEASE, FUSE_OPENDIR, and FUSE_RELEASEDIR operations, a minor opt
fusefs: implement FUSE_NO_OPEN_SUPPORT and FUSE_NO_OPENDIR_SUPPORT
For file systems that allow it, fusefs will skip FUSE_OPEN, FUSE_RELEASE, FUSE_OPENDIR, and FUSE_RELEASEDIR operations, a minor optimization.
MFC after: 2 weeks Reviewed by: pfg Differential Revision: https://reviews.freebsd.org/D32141
show more ...
|
#
b97c7abc |
| 18-Jun-2021 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: delete dead code
It was always dead, accidentally included in SVN r345876.
MFC after: 2 weeks Reviewed by: pfg
|
#
0b9a5c6f |
| 15-Jun-2021 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: improve warnings about buggy FUSE servers
The fusefs driver will print warning messages about FUSE servers that commit protocol violations. Previously it would print those warnings on every
fusefs: improve warnings about buggy FUSE servers
The fusefs driver will print warning messages about FUSE servers that commit protocol violations. Previously it would print those warnings on every violation, but that could spam the console. Now it will print each warning no more than once per lifetime of the mount. There is also now a dtrace probe for each violation.
MFC after: 2 weeks Sponsored by: Axcient Reviewed by: emaste, pfg Differential Revision: https://reviews.freebsd.org/D30780
show more ...
|
#
d63e6bc2 |
| 15-Jun-2021 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: delete dead code
Delete two fields in the per-mountpoint struct that have never been used.
MFC after: 2 weeks Sponsored by: Axcient
|
Revision tags: release/13.0.0 |
|
#
37df9d3b |
| 29-Dec-2020 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: update FUSE protocol to 7.24 and implement FUSE_LSEEK
FUSE_LSEEK reports holes on fuse file systems, and is used for example by bsdtar.
MFC after: 2 weeks Relnotes: yes Reviewed by: cem Dif
fusefs: update FUSE protocol to 7.24 and implement FUSE_LSEEK
FUSE_LSEEK reports holes on fuse file systems, and is used for example by bsdtar.
MFC after: 2 weeks Relnotes: yes Reviewed by: cem Differential Revision: https://reviews.freebsd.org/D27804
show more ...
|
#
4f4111d2 |
| 24-Dec-2020 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: delete some dead code
The original fusefs GSoC project seems to have envisioned exchanging two types of messages with FUSE servers. Perhaps vectored and non-vectored? But in practice only o
fusefs: delete some dead code
The original fusefs GSoC project seems to have envisioned exchanging two types of messages with FUSE servers. Perhaps vectored and non-vectored? But in practice only one type has ever been used. Delete the other type.
Reviewed by: cem Differential Revision: https://reviews.freebsd.org/D27770
show more ...
|
#
e3b1c847 |
| 09-Nov-2020 |
Edward Tomasz Napierala <trasz@FreeBSD.org> |
Make it possible to mount a fuse filesystem, such as squashfuse, from a Linux binary. Should come handy for AppImages.
Reviewed by: asomers MFC after: 2 weeks Sponsored by: The FreeBSD Foundation D
Make it possible to mount a fuse filesystem, such as squashfuse, from a Linux binary. Should come handy for AppImages.
Reviewed by: asomers MFC after: 2 weeks Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D26959
show more ...
|
Revision tags: release/12.2.0, release/11.4.0, release/12.1.0 |
|
#
0b4275ac |
| 07-Aug-2019 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: merge from projects/fuse2
This commit imports the new fusefs driver. It raises the protocol level from 7.8 to 7.23, fixes many bugs, adds a test suite for the driver, and adds many new featu
fusefs: merge from projects/fuse2
This commit imports the new fusefs driver. It raises the protocol level from 7.8 to 7.23, fixes many bugs, adds a test suite for the driver, and adds many new features. New features include:
* Optional kernel-side permissions checks (-o default_permissions) * Implement VOP_MKNOD, VOP_BMAP, and VOP_ADVLOCK * Allow interrupting FUSE operations * Support named pipes and unix-domain sockets in fusefs file systems * Forward UTIME_NOW during utimensat(2) to the daemon * kqueue support for /dev/fuse * Allow updating mounts with "mount -u" * Allow exporting fusefs file systems over NFS * Server-initiated invalidation of the name cache or data cache * Respect RLIMIT_FSIZE * Try to support servers as old as protocol 7.4
Performance enhancements include:
* Implement FUSE's FOPEN_KEEP_CACHE and FUSE_ASYNC_READ flags * Cache file attributes * Cache lookup entries, both positive and negative * Server-selectable cache modes: writethrough, writeback, or uncached * Write clustering * Readahead * Use counter(9) for statistical reporting
PR: 199934 216391 233783 234581 235773 235774 235775 PR: 236226 236231 236236 236291 236329 236381 236405 PR: 236327 236466 236472 236473 236474 236530 236557 PR: 236560 236844 237052 237181 237588 238565 Reviewed by: bcr (man pages) Reviewed by: cem, ngie, rpokala, glebius, kib, bde, emaste (post-commit review on project branch) MFC after: 3 weeks Relnotes: yes Sponsored by: The FreeBSD Foundation Pull Request: https://reviews.freebsd.org/D21110
show more ...
|
#
ed74f781 |
| 18-Jul-2019 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: add a intr/nointr mount option
FUSE file systems can optionally support interrupting outstanding operations. However, the file system does not identify to the kernel at mount time whether i
fusefs: add a intr/nointr mount option
FUSE file systems can optionally support interrupting outstanding operations. However, the file system does not identify to the kernel at mount time whether it's capable of doing that. Instead it signals its noncapability by returning ENOSYS to the first FUSE_INTERRUPT operation it receives. That's a problem for reliable signal delivery, because the kernel must choose which thread should get a signal before it knows whether the FUSE server can handle interrupts. The problem is even worse because the FUSE protocol allows a file system to simply ignore all FUSE_INTERRUPT operations.
Fix the signal delivery logic by making interruptibility an opt-in mount option. This will require a corresponding change to libfuse, but not to most file systems that link to libfuse.
Bump __FreeBSD_version due to the new mount option.
Sponsored by: The FreeBSD Foundation
show more ...
|
Revision tags: release/11.3.0 |
|
#
8aafc8c3 |
| 28-Jun-2019 |
Alan Somers <asomers@FreeBSD.org> |
[skip ci] update copyright headers in fusefs files
Sponsored by: The FreeBSD Foundation
|
#
f8ebf1cd |
| 26-Jun-2019 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: implement protocol 7.23's FUSE_WRITEBACK_CACHE option
As of protocol 7.23, fuse file systems can specify their cache behavior on a per-mountpoint basis. If they set FUSE_WRITEBACK_CACHE in
fusefs: implement protocol 7.23's FUSE_WRITEBACK_CACHE option
As of protocol 7.23, fuse file systems can specify their cache behavior on a per-mountpoint basis. If they set FUSE_WRITEBACK_CACHE in fuse_init_out.flags, then they'll get the writeback cache. If not, then they'll get the writethrough cache. If they set FOPEN_DIRECT_IO in every FUSE_OPEN response, then they'll get no cache at all.
The old vfs.fusefs.data_cache_mode sysctl is ignored for servers that use protocol 7.23 or later. However, it's retained for older servers, especially for those running in jails that lack access to the new protocol.
This commit also fixes two other minor test bugs: * WriteCluster:SetUp was using an uninitialized variable. * Read.direct_io_pread wasn't verifying that the cache was actually bypassed.
Sponsored by: The FreeBSD Foundation
show more ...
|
#
205696a1 |
| 26-Jun-2019 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: delete some unused mount options
The fusefs kernel module allegedly supported no_attrcache, no_readahed, no_datacache, no_namecache, and no_mmap mount options, but the mount_fusefs binary ne
fusefs: delete some unused mount options
The fusefs kernel module allegedly supported no_attrcache, no_readahed, no_datacache, no_namecache, and no_mmap mount options, but the mount_fusefs binary never did. So there was no way to ever activate these options. Delete them. Some of them have alternatives:
no_attrcache: set the attr_valid time to 0 in FUSE_LOOKUP and FUSE_GETATTR responses. no_readahed: set max_readahead to 0 in the FUSE_INIT response. no_datacache: set the vfs.fusefs.data_cache_mode sysctl to 0, or (coming soon) set the attr_valid time to 0 and set FUSE_AUTO_INVAL_DATA in the FUSE_INIT response. no_namecache: set entry_valid time to 0 in FUSE_LOOKUP and FUSE_GETATTR responses.
Sponsored by: The FreeBSD Foundation
show more ...
|
#
fef46454 |
| 26-Jun-2019 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: implement the "time_gran" feature.
If a server supports a timestamp granularity other than 1ns, it can tell the client this as of protocol 7.23. The client will use that granularity when up
fusefs: implement the "time_gran" feature.
If a server supports a timestamp granularity other than 1ns, it can tell the client this as of protocol 7.23. The client will use that granularity when updating its cached timestamps during write. This way the timestamps won't appear to change following flush.
Sponsored by: The FreeBSD Foundation
show more ...
|
#
a1c9f4ad |
| 20-Jun-2019 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: implement VOP_BMAP
If the fuse daemon supports FUSE_BMAP, then use that for the block mapping. Otherwise, use the same technique used by vop_stdbmap. Report large values for runp and runb i
fusefs: implement VOP_BMAP
If the fuse daemon supports FUSE_BMAP, then use that for the block mapping. Otherwise, use the same technique used by vop_stdbmap. Report large values for runp and runb in order to maximize read clustering and minimize upcalls, even if we don't know the true layout.
The major result of this change is that sequential reads to FUSE files will now usually happen 128KB at a time instead of 64KB.
Sponsored by: The FreeBSD Foundation
show more ...
|
#
d569012f |
| 17-Jun-2019 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: implement non-clustered readahead
fusefs will now read ahead at most one cache block at a time (usually 64 KB). Clustered reads are still TODO. Individual file systems may disable read ahe
fusefs: implement non-clustered readahead
fusefs will now read ahead at most one cache block at a time (usually 64 KB). Clustered reads are still TODO. Individual file systems may disable read ahead by setting fuse_init_out.max_readahead=0 during initialization.
Sponsored by: The FreeBSD Foundation
show more ...
|
#
e97ae4ad |
| 24-May-2019 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: implement FUSE_ASYNC_READ
If a daemon sets the FUSE_ASYNC_READ flag during initialization, then the client is allowed to issue multiple concurrent reads for the same file handle. Otherwise
fusefs: implement FUSE_ASYNC_READ
If a daemon sets the FUSE_ASYNC_READ flag during initialization, then the client is allowed to issue multiple concurrent reads for the same file handle. Otherwise concurrent reads are not allowed. This commit implements it. Previously we unconditionally disallowed concurrent reads.
Sponsored by: The FreeBSD Foundation
show more ...
|
#
e5b50fe7 |
| 23-May-2019 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: Make fuse file systems NFS-exportable
This commit adds the VOPs needed by userspace NFS servers (tested with net/unfs3). More work is needed to make the in-kernel nfsd work, because of its
fusefs: Make fuse file systems NFS-exportable
This commit adds the VOPs needed by userspace NFS servers (tested with net/unfs3). More work is needed to make the in-kernel nfsd work, because of its stateless nature. It doesn't open files prior to doing I/O. Also, the NFS-related VOPs currently ignore the entry cache.
Sponsored by: The FreeBSD Foundation
show more ...
|
#
a6fac00c |
| 21-May-2019 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: Allow update mounts
Allow "mount -u" to change some mount options for fusefs.
Sponsored by: The FreeBSD Foundation
|
#
5940f822 |
| 13-May-2019 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: remove the vfs.fusefs.data_cache_invalidate sysctl
This sysctl was added > 6.5 years ago and I don't know why. The description seems at odds with the code. While it's supposed to "discard
fusefs: remove the vfs.fusefs.data_cache_invalidate sysctl
This sysctl was added > 6.5 years ago and I don't know why. The description seems at odds with the code. While it's supposed to "discard clean cached data" during VOP_INACTIVE, it looks like it would discard any cached data, clean or otherwise.
Sponsored by: The FreeBSD Foundation
show more ...
|
#
fcefa6ef |
| 13-May-2019 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: remove the vfs.fusefs.mmap_enable sysctl
This sysctl was added > 6.5 years ago for no clear reason. Perhaps it was intended to gate an unstable feature? But now there's no reason to global
fusefs: remove the vfs.fusefs.mmap_enable sysctl
This sysctl was added > 6.5 years ago for no clear reason. Perhaps it was intended to gate an unstable feature? But now there's no reason to globally disable mmap. I'm not deleting the -ono_mmap mount option just yet, because it might be useful as a workaround for bug 237588.
Sponsored by: The FreeBSD Foundation
show more ...
|
#
4d09e76a |
| 13-May-2019 |
Alan Somers <asomers@FreeBSD.org> |
fusefs: remove the vfs.fusefs.sync_resize syctl
This sysctl was added > 6.5 years ago for no clear purpose. I'm guessing that it may have had something to do with the incomplete attribute cache. Bu
fusefs: remove the vfs.fusefs.sync_resize syctl
This sysctl was added > 6.5 years ago for no clear purpose. I'm guessing that it may have had something to do with the incomplete attribute cache. But the attribute cache works now. Since there's no clear motivation for this sysctl, it's best to remove it.
Sponsored by: The FreeBSD Foundation
show more ...
|