From owner-freebsd-current@FreeBSD.ORG Tue Mar 10 13:40:04 2009 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 546671065673 for ; Tue, 10 Mar 2009 13:40:04 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id 238EE8FC1B for ; Tue, 10 Mar 2009 13:40:04 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from server.baldwin.cx (pool-98-109-39-197.nwrknj.fios.verizon.net [98.109.39.197]) by cyrus.watson.org (Postfix) with ESMTPSA id C2AA246B65; Tue, 10 Mar 2009 09:40:03 -0400 (EDT) Received: from localhost (john@localhost [127.0.0.1]) (authenticated bits=0) by server.baldwin.cx (8.14.3/8.14.3) with ESMTP id n2ADdYC5026352; Tue, 10 Mar 2009 09:39:58 -0400 (EDT) (envelope-from jhb@freebsd.org) From: John Baldwin To: "Paul B. Mahol" Date: Tue, 10 Mar 2009 09:32:26 -0400 User-Agent: KMail/1.9.7 References: <3a142e750903090615t63a594e8rbadd7f7231049180@mail.gmail.com> <200903091642.25311.jhb@freebsd.org> <3a142e750903091542x7514f74eod294cb15f4ddf1b8@mail.gmail.com> In-Reply-To: <3a142e750903091542x7514f74eod294cb15f4ddf1b8@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200903100932.26592.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH authentication, not delayed by milter-greylist-2.0.2 (server.baldwin.cx [127.0.0.1]); Tue, 10 Mar 2009 09:39:58 -0400 (EDT) X-Virus-Scanned: ClamAV 0.94.2/9084/Tue Mar 10 03:11:13 2009 on server.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-4.4 required=4.2 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham version=3.1.3 X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on server.baldwin.cx Cc: freebsd-current@freebsd.org Subject: Re: nullfs: panic: vrele: negative ref cnt X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 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: Tue, 10 Mar 2009 13:40:04 -0000 On Monday 09 March 2009 6:42:06 pm Paul B. Mahol wrote: > On 3/9/09, John Baldwin wrote: > > On Monday 09 March 2009 9:15:22 am Paul B. Mahol wrote: > >> Hi, > >> here is part of textdump: > >> > >> panic(c061db9e,0,c061cee6,88e,4,...) at panic+0x136 > >> vrele(c4326d9c,0,c433fb5f,82,c060f3c7,...) at vrele+0x111 > >> null_nodeget(c3fd4780,c4326d9c,c3ba8bf4,0,c3ba8be4,...) at > >> null_nodeget+0xa0 > >> null_bypass(c3ba8be0,c3f35a78,c3ba8c28) at null_bypass+0x141 > >> VOP_VPTOCNP_APV(c4340240,c3ba8be0,c061bf01,387,c3cecc00,...) at > >> VOP_VPTOCNP_APV+0xb3 > > > > Try this. null_bypass() can't handle VOP_VPTOCNP because VPTOCNP doesn't > > return a vnode that is locked and VREF'd, but just a vnode that is > > vhold()'d. > > This patch attempts to give nullfs a VOP_VPTONCP() method which remaps the > > directory vnode properly on return by locking the directory vnode while > > invoking null_nodeget(). > > It livelocks active vty into [ufs] state. Will try with WITNESS kernel soon. Oh, this is because it locks the directory while holding a leaf, so it's going to deadlock with pathname lookups. kib@'s patch is probably ok even if it is a bit slower. -- John Baldwin