From owner-freebsd-current Sat Dec 7 15:33:30 2002 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 0E8A637B401; Sat, 7 Dec 2002 15:33:28 -0800 (PST) Received: from obsecurity.dyndns.org (adsl-64-169-104-228.dsl.lsan03.pacbell.net [64.169.104.228]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3CE7743EBE; Sat, 7 Dec 2002 15:33:27 -0800 (PST) (envelope-from kris@obsecurity.org) Received: from rot13.obsecurity.org (rot13.obsecurity.org [10.0.0.5]) by obsecurity.dyndns.org (Postfix) with ESMTP id A772266BE3; Sat, 7 Dec 2002 15:33:26 -0800 (PST) Received: by rot13.obsecurity.org (Postfix, from userid 1000) id 799958DE; Sat, 7 Dec 2002 15:33:26 -0800 (PST) Date: Sat, 7 Dec 2002 15:33:26 -0800 From: Kris Kennaway To: Robert Watson Cc: Kris Kennaway , Lars Eggert , current@FreeBSD.ORG, jhb@FreeBSD.ORG, alfred@FreeBSD.org Subject: Re: LOR: filedesc structure -> pipe mutex Message-ID: <20021207233326.GA75251@rot13.obsecurity.org> References: <20021207043355.GA75597@rot13.obsecurity.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="WIyZ46R2i8wDzkSu" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4i Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --WIyZ46R2i8wDzkSu Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sat, Dec 07, 2002 at 08:58:26AM -0500, Robert Watson wrote: > On Fri, 6 Dec 2002, Kris Kennaway wrote: >=20 > > On Fri, Dec 06, 2002 at 07:18:03PM -0800, Lars Eggert wrote: > >=20 > > > >I'm getting this too: > >=20 > > After discussing this with various people on IRC, it was determined that > > this is not the place where the reversal is occurring, but since witness > > doesn't have the lock order defined it has to guess, and in this > > instance it is guessing the wrong way around. After adding the lock > > order to subr_witness.c I now get this:=20 >=20 > Yeah, we're exchanging some out-of-band e-mail on this: the basic problem > is that: >=20 > filedesc>pipe > pipe>sigio > sigio>proc > proc>filedesc >=20 > We're talking about some possible solutions, including deferred > signalling, etc, etc.=20 Here's another panic I got overnight: lock order reversal 1st 0xc4cbcd80 pipe mutex (pipe mutex) @ /local0/src-client/sys/kern/sys_p= ipe.c:465 2nd 0xc044e780 sigio lock (sigio lock) @ /local0/src-client/sys/kern/kern_= sig.c:2225 Debugger("witness_lock") Stopped at Debugger+0x54: xchgl %ebx,in_Debugger.0 db> trace Debugger(c03efc85,c044e780,c04141a3,c04141a3,c0416b5c) at Debugger+0x54 witness_lock(c044e780,8,c0416b5c,8b1,c4cbcd80) at witness_lock+0x667 _mtx_lock_flags(c044e780,0,c0416b5c,8b1,23) at _mtx_lock_flags+0xb1 pgsigio(c5cf3cf8,17,0,1ad,0) at pgsigio+0x30 pipe_read(c63b2c6c,d9539c7c,c4e91f00,0,c67608c0) at pipe_read+0x516 dofileread(c67608c0,c63b2c6c,4,bfbff533,1) at dofileread+0xd2 read(c67608c0,d9539d10,c043094c,407,3) at read+0x6b syscall(2f,2f,2f,0,bfbff534) at syscall+0x28e Xint0x80_syscall() at Xint0x80_syscall+0x1d --- syscall (3, FreeBSD ELF32, read), eip =3D 0x2812d1c8, esp =3D 0xbfbff50= 0, ebp =3D 0xbfbff700 --- db> Kris --WIyZ46R2i8wDzkSu Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.1 (FreeBSD) iD8DBQE98oVFWry0BWjoQKURAsGUAJ90X4JP4XlHU7OnjzjafIdSOTlIiQCgiYMA Zs0zBTiIunxHg6sU4gCHFow= =MlEC -----END PGP SIGNATURE----- --WIyZ46R2i8wDzkSu-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message