History log of /openbsd-src/sys/kern/vfs_subr.c (Results 51 – 75 of 327)
Revision Date Author Comments
# 8b23add8 13-Jul-2018 beck <beck@openbsd.org>

Unveiling unveil(2).
This brings unveil into the tree, disabled by default - Currently
this will return EPERM on all attempts to use it until we are
fully certain it is ready for people to start usin

Unveiling unveil(2).
This brings unveil into the tree, disabled by default - Currently
this will return EPERM on all attempts to use it until we are
fully certain it is ready for people to start using, but this
now allows for others to do more tweaking and experimentation.

Still needs to send the unveil's across forks and execs before
fully enabling.

Many thanks to robert@ and deraadt@ for extensive testing.
ok deraadt@

show more ...


# 3ae16189 02-Jul-2018 bluhm <bluhm@openbsd.org>

Use more list macros for v_dirtyblkhd.
OK mpi@


# f993456d 06-Jun-2018 bluhm <bluhm@openbsd.org>

The function dounmount() traverses the mnt_list in forward direction
to call vfs_busy() for all nested mount points. vfs_stall() called
vfs_busy() in reverser order for all mount points. Change the

The function dounmount() traverses the mnt_list in forward direction
to call vfs_busy() for all nested mount points. vfs_stall() called
vfs_busy() in reverser order for all mount points. Change the
direction of the latter to resolve the lock order conflict.
OK visa@

show more ...


# 55a0321d 04-Jun-2018 guenther <guenther@openbsd.org>

Add VB_DUPOK to suppress witness(4) warning of concurrent mount locks.
Use that in three places:
- vfs_stall()
- sys_mount()
- dounmount()'s MNT_FORCE-does-recursive-unmounts case

ok deraadt@ vis

Add VB_DUPOK to suppress witness(4) warning of concurrent mount locks.
Use that in three places:
- vfs_stall()
- sys_mount()
- dounmount()'s MNT_FORCE-does-recursive-unmounts case

ok deraadt@ visa@

show more ...


# 08107a0b 27-May-2018 visa <visa@openbsd.org>

Drop unnecessary `p' parameter from vget(9).

OK mpi@


# 6779cc64 08-May-2018 bluhm <bluhm@openbsd.org>

When looping over mount points, the FOREACH SAVE macro is not save.
The loop variable mp is protected by vfs_busy() so that it cannot
be unmounted. But the next mount point nmp could be unmounted wh

When looping over mount points, the FOREACH SAVE macro is not save.
The loop variable mp is protected by vfs_busy() so that it cannot
be unmounted. But the next mount point nmp could be unmounted while
VFS_SYNC() sleeps. As the loop in vfs_stall() does not destroy the
mount point, TAILQ_FOREACH_REVERSE without _SAVE is the correct
macro to use.
OK deraadt@ visa@

show more ...


# 75078e10 08-May-2018 mpi <mpi@openbsd.org>

Move the vfs stall "barrier" logic to a function. FREF() will soon
change and this has nothing to do with it.

ok visa@, bluhm@


# 383f1a3f 07-May-2018 bluhm <bluhm@openbsd.org>

Print the vp pointer in the vinvalbuf() panic strings.
OK mpi@


# 6e880534 02-May-2018 visa <visa@openbsd.org>

Remove proc from the parameters of vn_lock(). The parameter is
unnecessary because curproc always does the locking.

OK mpi@


# 36bb23f1 28-Apr-2018 visa <visa@openbsd.org>

Clean up the parameters of VOP_LOCK() and VOP_UNLOCK(). It is always
curproc that does the locking or unlocking, so the proc parameter
is pointless and can be dropped.

OK mpi@, deraadt@


# f7fa0173 07-Mar-2018 bluhm <bluhm@openbsd.org>

Remounting files systems read-only does not work reliably. There
are corner cases where ffs may leak blocks. So better revert and
unmount all file systems at reboot. The "init died" panic will be

Remounting files systems read-only does not work reliably. There
are corner cases where ffs may leak blocks. So better revert and
unmount all file systems at reboot. The "init died" panic will be
fixed in a different way.
OK deraadt@

show more ...


# 976e9839 10-Feb-2018 deraadt <deraadt@openbsd.org>

Syncronize filesystems to disk when suspending. Each mountpoint's vnodes
are pushed to disk. Dangling vnodes (unlinked files still in use) and
vnodes undergoing change by long-running syscalls are

Syncronize filesystems to disk when suspending. Each mountpoint's vnodes
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.

show more ...


# c247b514 14-Dec-2017 deraadt <deraadt@openbsd.org>

Don't bother using DETACH_FORCE for the softraid luns at reboot
time; the aggressive mountpoint destruction seems to hit insane
use-after-frees when we are already far on the way down.


# 823f741b 14-Dec-2017 deraadt <deraadt@openbsd.org>

Give vflush_vnode() a hint about vnodes we don't need to account as "busy".
Change mountpoint to RDONLY a little later. Seems to improve the
rw->ro transition a bit.


# 5bb1c267 11-Dec-2017 bluhm <bluhm@openbsd.org>

Format the vnode lists of ddb show mount properly in columns.
OK krw@


# 7efda1a1 11-Dec-2017 deraadt <deraadt@openbsd.org>

In uvm Chuck decided backing store would not be allocated proactively
for blocks re-fetchable from the filesystem. However at reboot time,
filesystems are unmounted, and since processes lack backing

In uvm Chuck decided backing store would not be allocated proactively
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

show more ...


# 25391ace 04-Dec-2017 mpi <mpi@openbsd.org>

Use _kernel_lock_held() instead of __mp_lock_held(&kernel_lock).

ok visa@


# 207fea71 31-Jul-2017 florian <florian@openbsd.org>

Give back some space to the ramdisk by compiling net/radix.c only
if we compile pf, ipsec, pipex or nfsserver.
Suggested by mpi some time ago.
Tweak & OK bluhm
deraadt assumes it's fair


# 6f84e71d 20-Apr-2017 visa <visa@openbsd.org>

Tweak lock inits to make the system runnable with witness(4)
on amd64 and i386.


# 6cb46c1d 04-Apr-2017 deraadt <deraadt@openbsd.org>

struct vfsconf is tightly packed, but let's M_ZERO it in case that ever
changes to avoid exposing userland memory.


# 37a17979 15-Jan-2017 bluhm <bluhm@openbsd.org>

When traversing the mount list, the current mount point is locked
with vfs_busy(). If the FOREACH_SAFE macro is used, the next pointer
is not locked and could be freed by another process. Unless
ne

When traversing the mount list, the current mount point is locked
with vfs_busy(). If the FOREACH_SAFE macro is used, the next pointer
is not locked and could be freed by another process. Unless
necessary, do not use _SAFE as it is unsafe. In vfs_unmountall()
the current pointer is actullay freed. Add a comment that this
race has to be fixed later.
OK krw@

show more ...


# 9bf48af2 10-Jan-2017 bluhm <bluhm@openbsd.org>

Replace manual for() loops with FOREACH() macro.
OK millert@


# 5b26e4e1 10-Jan-2017 bluhm <bluhm@openbsd.org>

Remove the unused olddp parameter from function dounmount().
OK mpi@ millert@


# 0bea3979 28-Sep-2016 kettenis <kettenis@openbsd.org>

Cast enum to u_int when doing a bounds check to avoid a clang warning that
the comparison is always true.

ok jca@, tedu@


# 15f80f08 16-Sep-2016 dlg <dlg@openbsd.org>

move the namecache_rb_tree from RB macros to RBT functions.

i had to shuffle the includes a bit. all the knowledge of the RB
tree is now inside vfs_cache.c, and all accesses are via cache_*
function

move the namecache_rb_tree from RB macros to RBT functions.

i had to shuffle the includes a bit. all the knowledge of the RB
tree is now inside vfs_cache.c, and all accesses are via cache_*
functions.

show more ...


12345678910>>...14