| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
sets all members of struct vattr to VNOVAL (-1) instead of 0, which is
what is appropriate here. The VATTR_NULL() macro is intended for
initialising struct vattr when setting attributes.
ok mpi@
|
|
|
|
|
|
|
|
|
|
|
| |
don't attempt to determine the size of the root inode. This is because
we don't need to know the size of directories and FBT_GETATTR will also
cause a deadlock if fuse_unmount(3) is called before the file system
has a chance to process fbufs.
Add corresponding regression test.
ok mpi@
|
|
|
|
|
|
|
| |
kernel calls to ensure that the UVM cache for memory mapped files is
up to date.
ok mpi@
|
|
|
|
|
|
|
| |
Currently ignores the a_waitfor argument and always invokes the file
system's fsync implementation synchronously.
ok mpi@
|
|
|
|
|
|
| |
Fix CID 1470236.
ok helg@
|
|
|
|
| |
ok mpi@
|
|
|
|
| |
ok mpi@
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
indefinitely and cannot be interrupted or killed. This is consistent
with how VFS system calls should behave. If the file system becomes
unresponsive then the only sane solution is for the user to kill the
file system daemon.
Implementing the equivalent of nfs -osoft or -ointr to either timeout
or allow the blocking FUSE operation to be interrupted can be considered
in a future patch.
ok mpi@
|
|
|
|
|
|
| |
implementations. Rely on the VFS layer to do the checking.
OK mpi@, helg@
|
| |
|
|
|
|
|
|
|
|
| |
file system can access it unless the allow_other mount options is
specified. The allow_other mount option makes the file system
available to other users just like any other mounted file system.
ok mpi@
|
|
|
|
|
|
|
| |
FUSE file system. fuse_get_context(3) will now return the correct
values.
ok mpi@
|
|
|
|
|
|
|
|
| |
Don't ask file system to check file access; always behave as if
default_permissions option was specified. (this may change in a later
commit)
ok mpi@
|
|
|
|
|
|
|
| |
super-user, the mode includes the sticky bit (S_ISVTX), and path
does not refer to a directory.
ok mpi@
|
|
|
|
|
|
| |
unlocking the directory vnode.
OK mpi@, helg@
|
|
|
|
| |
ok mpi@
|
|
|
|
|
|
|
| |
system's ino for VOP_GETATTR(9) and VOP_READDIR(9) rather than the
internally generated fuse ino.
ok mpi@
|
|
|
|
|
|
| |
doesn't implement it.
ok mpi@
|
|
|
|
|
|
| |
initialised. Rather than failing, requests are now queued.
ok mpi@
|
|
|
|
|
|
|
|
|
| |
VOP_CLOSE(9). The associated FUSE file handle is however not closed at this
time and is instead closed on VOP_RELEASE(9) because that's the only time
it's guaranteed to be no longer used. Directory handles are now only closed
on VOP_RELEASE(9) for the same reason.
ok mpi@
|
|
|
|
| |
ok mpi@
|
|
|
|
|
|
|
|
| |
opened multiple times (either from the same process or different
processes) then FUSE will not reliably return the directory entries to
both file descriptors.
ok mpi@
|
|
|
|
| |
recommendation.
|
|
|
|
|
|
| |
unnecessary because curproc always does the locking.
OK mpi@
|
|
|
|
|
|
|
| |
curproc that does the locking or unlocking, so the proc parameter
is pointless and can be dropped.
OK mpi@, deraadt@
|
|
|
|
| |
ok visa@
|
|
|
|
|
|
|
|
| |
to appease WITNESS. ext2fs and ffs already use the flag. The same
locking pattern appears with other file systems too, so this patch
addresses the remaining cases.
OK mpi@
|
|
|
|
|
|
|
|
|
|
| |
are pushed to disk. Dangling vnodes (unlinked files still in use) and
vnodes undergoing change by long-running syscalls are identified -- and
such filesystems are marked dirty on-disk while we are suspended (in case
power is lost, a fsck will be required). Filesystems without dangling or
busy vnodes are marked clean, resulting in faster boots following
"battery died" circumstances.
Tested by numerous developers, thanks for the feedback.
|
|
|
|
|
|
|
|
|
| |
Supervisor Mode Access Prevention (SMAP) compiled with FUSE_DEBUG.
While here, add some sanity check to the debug function fuse_dump_buff.
Thanks to Thomas Jeunet.
OK mpi@, helg@
|
|
|
|
|
|
|
| |
This should be enought to prevent `fp' to disapear while sleeping in
malloc(9).
ok helg@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
for blocks re-fetchable from the filesystem. However at reboot time,
filesystems are unmounted, and since processes lack backing store they
are killed. Since the scheduler is still running, in some cases init is
killed... which drops us to ddb [noted by bluhm]. Solution is to convert
filesystems to read-only [proposed by kettenis]. The tale follows:
sys_reboot() should pass proc * to MD boot() to vfs_shutdown() which
completes current IO with vfs_busy VB_WRITE|VB_WAIT, then calls VFS_MOUNT()
with MNT_UPDATE | MNT_RDONLY, soon teaching us that *fs_mount() calls a
copyin() late... so store the sizes in vfsconflist[] and move the copyin()
to sys_mount()... and notice nfs_mount copyin() is size-variant, so kill
legacy struct nfs_args3. Next we learn ffs_mount()'s MNT_UPDATE code is
sharp and rusty especially wrt softdep, so fix some bugs adn add
~MNT_SOFTDEP to the downgrade. Some vnodes need a little more help,
so tie them to &dead_vnops.
ffs_mount calling DIOCCACHESYNC is causing a bit of grief still but
this issue is seperate and will be dealt with in time.
couple hundred reboots by bluhm and myself, advice from guenther and
others at the hut
|
|
|
|
|
|
|
| |
support FBT_CREATE. Fall back to FBT_MKNOD + FBT_OPEN so that a valid
sequence of FUSE messages is sent to the file system when creating files.
input from mpi@, otto@
|
|
|
|
|
|
| |
Now aligns with link(2) man page and ffs regress tests.
ok phessler@, jca@
|
|
|
|
| |
input and ok mpi@
|
|
|
|
| |
ok mpi@
|
|
|
|
|
|
|
|
|
|
|
| |
Endless loop if directory nested more than one level from root of file system
Current directory not found if the parent directory contains more children than
will fit in the buffer passed to VOP_READDIR(9)
Open and close directory in fusefs_readdir if dir is not already open.
Now behaves as if readdir_ino option was passed to fuse so that directories in
path have a valid ino.
ok mpi@
|
|
|
|
|
|
| |
Found by Coverity Scan (CID 1453387)
OK mpi@
|
|
|
|
| |
on amd64 and i386.
|
|
|
|
| |
OK mpi@ millert@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
parent inode number for ".." lookups. This only works until the kernel
starts to reuse vnodes and the parent's vnode is reclaimed and the ino
to path mapping is removed from the userland process by libfuse. Fix
this by using reference counting in libfuse, so that parent mapping are
retained as long as a child uses them. Also, don't free the root node.
This commit resolves following issue:
$ doas fuse-zip ~/Downloads/foo.zip /mnt
$ ls /mnt
openbsd-www
$ grep -IR foo /usr/src > /dev/null # force vfs to reclaim vnodes
$ ls /mnt
ls: /mnt: No such file or directory
$
ok tedu
|
|
|
|
|
|
|
|
|
| |
vattr in userspace is suboptimal as some related helpers are not
available, e.g. VATTR_NULL() and IFTOVT(). The conversion is now done in
the kernel where it belongs. As a side effect the <sys/vnode.h> include
can be removed from libfuse.
tweaks and ok guenther
|
|
|
|
|
|
|
| |
updated struct vattr afterwards, so the call can be removed. Remove both
calls and the function itself, inlining the last remaining call.
ok millert
|
|
|
|
|
|
|
| |
filesystem the tree can change behind our back, resulting in stale cache
entries. "The only winning move is not to play."
ok tedu beck mpi
|
|
|
|
|
|
|
|
|
|
|
|
| |
under the assumption, that fuse_vget() has reasonable semantics, while
this is not the case. fusefs_vget() only functions correctly, if the
file in questions has recently been accessed and is still in the vnode
cache of the userspace daemon associated with the mount point.
As a matter of fact the fuse api doesn't feature a reasonable way to map
inode numbers to a handle at all (see struct fuse_operations).
ok guenther
|
|
|
|
|
|
| |
cast from FUSE_ROOTINO, as it is already included in the #define.
ok kettenis
|
|
|
|
|
|
|
|
|
|
|
| |
vtype in struct fusefs_node and v_type in struct vnode. Given the fact,
that fusefs_node structs are never allocated without an associated vnode
and those two fields are always in sync, one of those locations is
superfluous.
While there remove the unused nlookup field.
ok mpi
|
|
|
|
|
|
|
|
| |
trivial change to use rrw locks instead. All it needs is LK_* defines
for the RW_* flags.
tested by naddy and sthen on package building infrastructure
input and ok jmc mpi tedu
|
|
|
|
|
|
| |
left using it is fuse. It has been removed from all other filesystems.
ok millert deraadt
|
|
|
|
|
|
|
|
|
|
| |
msdosfs and nfsv2 don't set f_namemax. ntfs and ext2fs don't set
f_namemeax and f_favail. fusefs doesn't set f_mntfromspec, f_favail and
f_iosize. Also, make all filesystems use copy_statfs_info(), so that all
statfs information is filled in correctly for the (sb != &mp->mnt-stat)
case.
ok stefan
|
|
|
|
|
|
|
|
|
|
|
|
| |
could end up in an inconsistent state. The fstype dependent
mp->mnt_data was NULL, but the general mp was still listed as a
valid mount point. Next access to the file system would crash with
a NULL pointer dereference.
If closing the device fails, the mount point must go away anyway.
There is nothing we can do about it. Remove the workaround for the
EIO error in the general unmount code, but do not generate any error
in the file system specific unmount functions.
OK natano@ beck@
|