Date: Mon, 16 May 2016 11:48:43 +0000 (UTC) From: Andriy Gapon <avg@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r299938 - head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs Message-ID: <201605161148.u4GBmhvI058773@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: avg Date: Mon May 16 11:48:43 2016 New Revision: 299938 URL: https://svnweb.freebsd.org/changeset/base/299938 Log: fix up r299902: mount_snapshot requires that the covered vnode is locked Previously that was not strictly enforced. MFC after: 4 weeks X-MFC with: r299902 Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ctldir.c Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ctldir.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ctldir.c Mon May 16 10:51:35 2016 (r299937) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ctldir.c Mon May 16 11:48:43 2016 (r299938) @@ -1086,6 +1086,7 @@ domount: (void) snprintf(mountpoint, mountpoint_len, "%s/" ZFS_CTLDIR_NAME "/snapshot/%s", dvp->v_vfsp->mnt_stat.f_mntonname, nm); + VERIFY0(vn_lock(*vpp, LK_EXCLUSIVE)); err = mount_snapshot(curthread, vpp, "zfs", mountpoint, snapname, 0); kmem_free(mountpoint, mountpoint_len); if (err == 0) {
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201605161148.u4GBmhvI058773>