From owner-freebsd-current@FreeBSD.ORG Fri Dec 12 15:44:11 2003 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CB62616A4CE; Fri, 12 Dec 2003 15:44:11 -0800 (PST) Received: from mail.chesapeake.net (chesapeake.net [208.142.252.6]) by mx1.FreeBSD.org (Postfix) with ESMTP id AEFCF43D09; Fri, 12 Dec 2003 15:44:09 -0800 (PST) (envelope-from jroberson@chesapeake.net) Received: from localhost (jroberson@localhost) by mail.chesapeake.net (8.11.6/8.11.6) with ESMTP id hBCNi5s74331; Fri, 12 Dec 2003 18:44:05 -0500 (EST) (envelope-from jroberson@chesapeake.net) Date: Fri, 12 Dec 2003 18:44:05 -0500 (EST) From: Jeff Roberson To: Don Lewis In-Reply-To: <200312121835.hBCIZZeF058658@gw.catspoiler.org> Message-ID: <20031212184001.C4201-100000@mail.chesapeake.net> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: kuriyama@imgsrc.co.jp cc: freebsd-current@freebsd.org Subject: Re: vn_fullpath: 0xc85e24a0 is not locked but should be X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 12 Dec 2003 23:44:11 -0000 On Fri, 12 Dec 2003, Don Lewis wrote: > On 12 Dec, Jun Kuriyama wrote: > > At Thu, 11 Dec 2003 23:14:50 -0500 (EST), > > Robert Watson wrote: > >> Ah, you're still runing with the VFS lock debugging :-). Indeed, it looks > >> like a vn_lock() and unlock of p->p_textvp is missing in > >> procfs_doprocfile(), even though that likely would violate the VFS lock > >> order. The attached (untested) patch might well fix it, but might not be > >> right -- I'm not sure that curthread holds a valid reference to > >> p->p_textvp that can't evaporate during these operations. I'm not sure > >> the proc reference stuff protects us properly here, but John would know > >> (CC'd). > >> > >> Index: procfs.c > >> =================================================================== > >> RCS file: /home/ncvs/src/sys/fs/procfs/procfs.c,v > >> retrieving revision 1.9 > >> diff -u -r1.9 procfs.c > >> --- procfs.c 17 Apr 2003 22:12:12 -0000 1.9 > >> +++ procfs.c 12 Dec 2003 04:13:10 -0000 > >> @@ -70,7 +70,9 @@ > >> char *fullpath = "unknown"; > >> char *freepath = NULL; > >> > >> + vn_lock(p->p_textvp, LK_EXCLUSIVE | LK_RETRY, td); > >> vn_fullpath(td, p->p_textvp, &fullpath, &freepath); > >> + VOP_UNLOCK(p->p_textvp, 0, td); > >> sbuf_printf(sb, "%s", fullpath); > >> if (freepath) > >> free(freepath, M_TEMP); > > > > Okay, I'll wait without DEBUG_VFS_LOCKS until fix is committed. > > DEBUG_VFS_LOCKS is quite usable as long as you don't run find, tar, etc. > that traverses procfs. This isn't entirely relevant, but I'd like to point out how happy I am that it works even this much. When I started fixing up VFS we couldn't even run init without DEBUG_VFS_LOCKS panicing. It took me a few weeks of hacking to get the system running anything useful with all of these assertions. A lot of other people have put significant effort in along the way as well. I'm very happy to see the progress. Thanks folks. Cheers, Jeff > _______________________________________________ > freebsd-current@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-current > To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org" >