Date: Sat, 04 Apr 2009 01:26:14 +0300 From: Giorgos Keramidas <keramida@ceid.upatras.gr> To: Peter Wemm <peter@FreeBSD.org> Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r190655 - head/sys/kern Message-ID: <87y6uhqsqh.fsf@kobe.laptop> In-Reply-To: <200904022116.n32LGK81076210@svn.freebsd.org> (Peter Wemm's message of "Thu, 2 Apr 2009 21:16:20 %2B0000 (UTC)") References: <200904022116.n32LGK81076210@svn.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 2 Apr 2009 21:16:20 +0000 (UTC), Peter Wemm <peter@FreeBSD.org> wrote: > Author: peter > Date: Thu Apr 2 21:16:20 2009 > New Revision: 190655 > URL: http://svn.freebsd.org/changeset/base/190655 > > Log: > vn_vptocnp() unlocks the name cache and forgets to re-lock it before > returning in one error case, and mistakenly unlocks it for the > umount -f case. > > Modified: > head/sys/kern/vfs_cache.c > > Modified: head/sys/kern/vfs_cache.c > ============================================================================== > --- head/sys/kern/vfs_cache.c Thu Apr 2 19:27:56 2009 (r190654) > +++ head/sys/kern/vfs_cache.c Thu Apr 2 21:16:20 2009 (r190655) > @@ -971,6 +971,7 @@ vn_vptocnp(struct vnode **vp, char **bp, > vdrop(*vp); > VFS_UNLOCK_GIANT(vfslocked); > if (error) { > + CACHE_RLOCK(); > numfullpathfail2++; > return (error); > } > @@ -979,7 +980,6 @@ vn_vptocnp(struct vnode **vp, char **bp, > CACHE_RLOCK(); > if ((*vp)->v_iflag & VI_DOOMED) { > /* forced unmount */ > - CACHE_RUNLOCK(); > vdrop(*vp); > return (ENOENT); > } This seems to trigger panics for nullfs mounts: System call __getcwd returning with the following locks held: shared rw Name Cache (Name Cache) r = 0 (0xc0ba245c) locked @ /usr/src/sys/kern/vfs_cache.c:980 panic: witness_warn
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?87y6uhqsqh.fsf>