From owner-freebsd-fs@FreeBSD.ORG Fri Apr 28 14:25:29 2006 Return-Path: X-Original-To: freebsd-fs@FreeBSD.org Delivered-To: freebsd-fs@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 560A616A401 for ; Fri, 28 Apr 2006 14:25:29 +0000 (UTC) (envelope-from pjd@garage.freebsd.pl) Received: from mail.garage.freebsd.pl (arm132.internetdsl.tpnet.pl [83.17.198.132]) by mx1.FreeBSD.org (Postfix) with ESMTP id 076E943D58 for ; Fri, 28 Apr 2006 14:25:22 +0000 (GMT) (envelope-from pjd@garage.freebsd.pl) Received: by mail.garage.freebsd.pl (Postfix, from userid 65534) id 72D2E52C6D; Fri, 28 Apr 2006 16:25:21 +0200 (CEST) Received: from localhost (ana50.internetdsl.tpnet.pl [83.17.82.50]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.garage.freebsd.pl (Postfix) with ESMTP id 9BCE851D2C; Fri, 28 Apr 2006 16:25:14 +0200 (CEST) Date: Fri, 28 Apr 2006 16:23:49 +0200 From: Pawel Jakub Dawidek To: Kostik Belousov Message-ID: <20060428142349.GE864@garage.freebsd.pl> References: <20060428120855.GB1270@deviant.kiev.zoral.com.ua> <20060428140205.GD864@garage.freebsd.pl> <20060428141617.GD1270@deviant.kiev.zoral.com.ua> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="3O1VwFp74L81IIeR" Content-Disposition: inline In-Reply-To: <20060428141617.GD1270@deviant.kiev.zoral.com.ua> X-PGP-Key-URL: http://people.freebsd.org/~pjd/pjd.asc X-OS: FreeBSD 7.0-CURRENT i386 User-Agent: mutt-ng/devel-r535 (FreeBSD) X-Spam-Checker-Version: SpamAssassin 3.0.4 (2005-06-05) on mail.garage.freebsd.pl X-Spam-Level: X-Spam-Status: No, score=-5.9 required=3.0 tests=ALL_TRUSTED,BAYES_00 autolearn=ham version=3.0.4 Cc: freebsd-fs@FreeBSD.org Subject: Re: vn_start_write(9) recursion ? X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 28 Apr 2006 14:25:29 -0000 --3O1VwFp74L81IIeR Content-Type: text/plain; charset=iso-8859-2 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Apr 28, 2006 at 05:16:17PM +0300, Kostik Belousov wrote: +> On Fri, Apr 28, 2006 at 04:02:05PM +0200, Pawel Jakub Dawidek wrote: +> > On Fri, Apr 28, 2006 at 03:08:55PM +0300, Kostik Belousov wrote: +> > +> vn_start_write(9) shall not be called recursively (at least, not wi= thout +> > +> V_NOWAIT flag). Otherwise, system may deadlock if vn_write_suspend(= 9) +> > +> is called between. +> >=20 +> > Yes, you are right. Nice catch, actually. +> >=20 +> > I hacked this patch to detect it: +> >=20 +> > http://people.freebsd.org/~pjd/patches/vn_start_write_recursion.patch +> >=20 +> > And it panics on boot. +>=20 +> Incredible ! Please, commit it ! Not sure if this is good idea to abuse td_pflags for debugging purpose... But we have plenty of room in there, so maybe its worth it. I'll ask few other guys what they think about it. +> This would save me at least a day starring at struct mount with +> mnt_writeopcount and (still) no writers. +>=20 +> For instance, such situation occurs in quotactl/quotaoff case. This could be the hang I'm chasing, btw:) --=20 Pawel Jakub Dawidek http://www.wheel.pl pjd@FreeBSD.org http://www.FreeBSD.org FreeBSD committer Am I Evil? Yes, I Am! --3O1VwFp74L81IIeR Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (FreeBSD) iD8DBQFEUiV1ForvXbEpPzQRAjyWAJ9xjLxIpOzDQUvKvu5mgqxRE23bxgCcCcVd fqu4s9HlHqarZ2T6KYBqHM8= =2Hw3 -----END PGP SIGNATURE----- --3O1VwFp74L81IIeR--