diff options
author | dillon <dillon@FreeBSD.org> | 1998-12-12 21:07:09 +0000 |
---|---|---|
committer | dillon <dillon@FreeBSD.org> | 1998-12-12 21:07:09 +0000 |
commit | 127655f6ddbdc440718336f96821295020e660e5 (patch) | |
tree | 6058a8e0fd71cd015d75d2d5bd971e1d86d7f8fe /sys/kern/vfs_syscalls.c | |
parent | 4a5ab955ca5be11c420646ad76e13e55113ada02 (diff) | |
download | FreeBSD-src-127655f6ddbdc440718336f96821295020e660e5.zip FreeBSD-src-127655f6ddbdc440718336f96821295020e660e5.tar.gz |
PR: kern/8965
Obtained from: Stephen Clawson <sclawson@cs.utah.edu>
Wakeup anyone waiting on a mount point prior to returning from umount,
whether an error occurs or not. Fixes a stat/NFS-umount race and other
potential future problems. Fix taken from bug/pr which also indicated
that the same fix has already been applied to OpenBSD and NetBSD.
Diffstat (limited to 'sys/kern/vfs_syscalls.c')
-rw-r--r-- | sys/kern/vfs_syscalls.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index 1482df6..5f2b992 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -36,7 +36,7 @@ * SUCH DAMAGE. * * @(#)vfs_syscalls.c 8.13 (Berkeley) 4/15/94 - * $Id: vfs_syscalls.c,v 1.109 1998/11/03 08:01:47 peter Exp $ + * $Id: vfs_syscalls.c,v 1.110 1998/11/03 14:29:09 peter Exp $ */ /* For 4.3 integer FS ID compatibility */ @@ -494,6 +494,8 @@ dounmount(mp, flags, p) mp->mnt_flag |= async_flag; lockmgr(&mp->mnt_lock, LK_RELEASE | LK_INTERLOCK | LK_REENABLE, &mountlist_slock, p); + if (mp->mnt_kern_flag & MNTK_MWAIT) + wakeup((caddr_t)mp); return (error); } CIRCLEQ_REMOVE(&mountlist, mp, mnt_list); |