diff options
author | Martin Pieuchot <mpi@cvs.openbsd.org> | 2018-05-08 08:58:50 +0000 |
---|---|---|
committer | Martin Pieuchot <mpi@cvs.openbsd.org> | 2018-05-08 08:58:50 +0000 |
commit | 7a3f425a437bf72f0ce1279c83be4acd0c57d50a (patch) | |
tree | d391174a91483eab04fa24538682cc1545e39c63 /sys/kern/vfs_subr.c | |
parent | b1791167b5ee74c8d0c677267cc654141043b98e (diff) |
Move the vfs stall "barrier" logic to a function. FREF() will soon
change and this has nothing to do with it.
ok visa@, bluhm@
Diffstat (limited to 'sys/kern/vfs_subr.c')
-rw-r--r-- | sys/kern/vfs_subr.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c index f600bcff117..149819a0664 100644 --- a/sys/kern/vfs_subr.c +++ b/sys/kern/vfs_subr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: vfs_subr.c,v 1.270 2018/05/07 15:24:05 bluhm Exp $ */ +/* $OpenBSD: vfs_subr.c,v 1.271 2018/05/08 08:58:49 mpi Exp $ */ /* $NetBSD: vfs_subr.c,v 1.53 1996/04/22 01:39:13 christos Exp $ */ /* @@ -1627,6 +1627,13 @@ vfs_stall(struct proc *p, int stall) return (allerror); } +void +vfs_stall_barrier(void) +{ + rw_enter_read(&vfs_stall_lock); + rw_exit_read(&vfs_stall_lock); +} + /* * Unmount all file systems. * We traverse the list in reverse order under the assumption that doing so |