diff options
author | tegge <tegge@FreeBSD.org> | 2006-09-26 04:21:20 +0000 |
---|---|---|
committer | tegge <tegge@FreeBSD.org> | 2006-09-26 04:21:20 +0000 |
commit | 688c3982c5e7708fb145972d37468804f7c9c9a8 (patch) | |
tree | 9b794a18c9c9d4e7823d1a88395fec20752c6ee4 | |
parent | 89ea8a9b1bc6f1c756ee30736d24464f17a00879 (diff) | |
download | FreeBSD-src-688c3982c5e7708fb145972d37468804f7c9c9a8.zip FreeBSD-src-688c3982c5e7708fb145972d37468804f7c9c9a8.tar.gz |
Protect change to bo_flag by holding the bufobj mutex.
-rw-r--r-- | sys/ufs/ffs/ffs_vfsops.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/ufs/ffs/ffs_vfsops.c b/sys/ufs/ffs/ffs_vfsops.c index 1c8c4d3..87bfd9f 100644 --- a/sys/ufs/ffs/ffs_vfsops.c +++ b/sys/ufs/ffs/ffs_vfsops.c @@ -849,7 +849,9 @@ ffs_mountfs(devvp, mp, td) * Our bufobj must require giant for snapshots when quotas are * enabled. */ + BO_LOCK(&devvp->v_bufobj); devvp->v_bufobj.bo_flag |= BO_NEEDSGIANT; + BO_UNLOCK(&devvp->v_bufobj); #else MNT_ILOCK(mp); mp->mnt_kern_flag |= MNTK_MPSAFE; |