Move vfs_stall_barrier() from the fd layer into vn_lock() and the vfs layer.
authorclaudio <claudio@openbsd.org>
Thu, 21 Oct 2021 09:59:13 +0000 (09:59 +0000)
committerclaudio <claudio@openbsd.org>
Thu, 21 Oct 2021 09:59:13 +0000 (09:59 +0000)
commitfae85b1e6961525c0b9017bb021d98e19c2e4451
treeb15e3d1f67a36d2ecc1b3fc618f1fae2725bb1dd
parent92d29f8fce676c9e419391df00d7aad17305a2fc
Move vfs_stall_barrier() from the fd layer into vn_lock() and the vfs layer.
vfs stalling is used by suspend/resume and by vmt(4) to stall any
filesystem operation from altering the state on disk. All these
operations will call vn_lock and be stalled. Adjust vfs_stall_barrier()
to allow the lock owner to still progress so that suspend can sync
the filesystems after stalling vfs operation.
OK mpi@
sys/kern/kern_descrip.c
sys/kern/vfs_subr.c
sys/kern/vfs_vnops.c
sys/sys/file.h