Date: Tue, 17 Jan 2012 16:20:51 +0000 (UTC) From: Alan Cox <alc@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r230268 - head/sys/kern Message-ID: <201201171620.q0HGKpLx097740@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: alc Date: Tue Jan 17 16:20:50 2012 New Revision: 230268 URL: http://svn.freebsd.org/changeset/base/230268 Log: Explain why it is safe to unlock the vnode. Requested by: kib Modified: head/sys/kern/imgact_elf.c Modified: head/sys/kern/imgact_elf.c ============================================================================== --- head/sys/kern/imgact_elf.c Tue Jan 17 15:20:41 2012 (r230267) +++ head/sys/kern/imgact_elf.c Tue Jan 17 16:20:50 2012 (r230268) @@ -800,6 +800,9 @@ __CONCAT(exec_, __elfN(imgact))(struct i * than zero. Consequently, the vnode lock is not needed by vrele(). * However, in cases where the vnode lock is external, such as nullfs, * v_usecount may become zero. + * + * The VV_TEXT flag prevents modifications to the executable while + * the vnode is unlocked. */ VOP_UNLOCK(imgp->vp, 0);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201201171620.q0HGKpLx097740>