Deleted Added
full compact
vfs_export.c (31016) vfs_export.c (31132)
1/*
2 * Copyright (c) 1989, 1993
3 * The Regents of the University of California. All rights reserved.
4 * (c) UNIX System Laboratories, Inc.
5 * All or some portions of this file are derived from material licensed
6 * to the University of California by American Telephone and Telegraph
7 * Co. or Unix System Laboratories, Inc. and are reproduced herein with
8 * the permission of UNIX System Laboratories, Inc.

--- 22 unchanged lines hidden (view full) ---

31 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
32 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
33 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
36 * SUCH DAMAGE.
37 *
38 * @(#)vfs_subr.c 8.31 (Berkeley) 5/26/95
1/*
2 * Copyright (c) 1989, 1993
3 * The Regents of the University of California. All rights reserved.
4 * (c) UNIX System Laboratories, Inc.
5 * All or some portions of this file are derived from material licensed
6 * to the University of California by American Telephone and Telegraph
7 * Co. or Unix System Laboratories, Inc. and are reproduced herein with
8 * the permission of UNIX System Laboratories, Inc.

--- 22 unchanged lines hidden (view full) ---

31 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
32 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
33 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
36 * SUCH DAMAGE.
37 *
38 * @(#)vfs_subr.c 8.31 (Berkeley) 5/26/95
39 * $Id: vfs_subr.c,v 1.111 1997/10/26 20:55:07 phk Exp $
39 * $Id: vfs_subr.c,v 1.112 1997/11/07 08:53:11 phk Exp $
40 */
41
42/*
43 * External virtual filesystem routines
44 */
45#include "opt_ddb.h"
46#include "opt_devfs.h"
47

--- 94 unchanged lines hidden (view full) ---

142vfs_busy(mp, flags, interlkp, p)
143 struct mount *mp;
144 int flags;
145 struct simplelock *interlkp;
146 struct proc *p;
147{
148 int lkflags;
149
40 */
41
42/*
43 * External virtual filesystem routines
44 */
45#include "opt_ddb.h"
46#include "opt_devfs.h"
47

--- 94 unchanged lines hidden (view full) ---

142vfs_busy(mp, flags, interlkp, p)
143 struct mount *mp;
144 int flags;
145 struct simplelock *interlkp;
146 struct proc *p;
147{
148 int lkflags;
149
150 if (mp->mnt_flag & MNT_UNMOUNT) {
150 if (mp->mnt_kern_flag & MNTK_UNMOUNT) {
151 if (flags & LK_NOWAIT)
152 return (ENOENT);
151 if (flags & LK_NOWAIT)
152 return (ENOENT);
153 mp->mnt_flag |= MNT_MWAIT;
153 mp->mnt_kern_flag |= MNTK_MWAIT;
154 if (interlkp) {
155 simple_unlock(interlkp);
156 }
157 /*
158 * Since all busy locks are shared except the exclusive
159 * lock granted when unmounting, the only place that a
160 * wakeup needs to be done is at the release of the
161 * exclusive lock at the end of dounmount.

--- 1950 unchanged lines hidden ---
154 if (interlkp) {
155 simple_unlock(interlkp);
156 }
157 /*
158 * Since all busy locks are shared except the exclusive
159 * lock granted when unmounting, the only place that a
160 * wakeup needs to be done is at the release of the
161 * exclusive lock at the end of dounmount.

--- 1950 unchanged lines hidden ---