From owner-freebsd-current@FreeBSD.ORG Mon Jun 28 14:37:49 2010 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 4D87D1065675; Mon, 28 Jun 2010 14:37:49 +0000 (UTC) (envelope-from des@des.no) Received: from smtp.des.no (smtp.des.no [194.63.250.102]) by mx1.freebsd.org (Postfix) with ESMTP id 0E5268FC0C; Mon, 28 Jun 2010 14:37:48 +0000 (UTC) Received: from ds4.des.no (des.no [84.49.246.2]) by smtp.des.no (Postfix) with ESMTP id 05CE51FFC33; Mon, 28 Jun 2010 14:37:48 +0000 (UTC) Received: by ds4.des.no (Postfix, from userid 1001) id C4C2084525; Mon, 28 Jun 2010 16:35:36 +0200 (CEST) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: "M. Warner Losh" References: <20100627.201716.1108826596298620201.imp@bsdimp.com> <86iq537egy.fsf@ds4.des.no> <20100628.081810.502133560696912792.imp@bsdimp.com> Date: Mon, 28 Jun 2010 16:35:36 +0200 In-Reply-To: <20100628.081810.502133560696912792.imp@bsdimp.com> (M. Warner Losh's message of "Mon, 28 Jun 2010 08:18:10 -0600 (MDT)") Message-ID: <86pqzb5io7.fsf@ds4.des.no> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: yanefbsd@gmail.com, freebsd-current@freebsd.org, pjd@freebsd.org, hselasky@c2i.net Subject: Re: Patch for rc.d/devd on FreeBSD 9-current 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: Mon, 28 Jun 2010 14:37:49 -0000 "M. Warner Losh" writes: > Dag-Erling Sm=C3=B8rgrav writes: > > "M. Warner Losh" writes: > > > Maybe the real problem is that devd locks the file, then dies. The > > > file remains locked, so the flopen is failing with EWOULDBLOCK. > > The lock is released when the process that holds it terminates. > So which process is that? devd took it out, and is subsequently > killed. When it restarts, it can't take out the lock. What does fstat say about the pid file? > The same code works perfectly in 8.0-stable from April. > > The conclusion, I believe, is that somebody broke locking in > current... Before I wrote one of my earlier replies, I traced through the code paths that lead to a lock being released, and everything looks fine and dandy. Besides, if someone had, as you suggest, broken locking in current, there would be a lot more noise about it on the lists. DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no