From owner-freebsd-current Wed Nov 29 9: 9:44 2000 Delivered-To: freebsd-current@freebsd.org Received: from pike.osd.bsdi.com (pike.osd.bsdi.com [204.216.28.222]) by hub.freebsd.org (Postfix) with ESMTP id 6E62D37B69B for ; Wed, 29 Nov 2000 09:09:41 -0800 (PST) Received: from laptop.baldwin.cx (john@dhcp246.osd.bsdi.com [204.216.28.246]) by pike.osd.bsdi.com (8.11.1/8.9.3) with ESMTP id eATH9VC22106; Wed, 29 Nov 2000 09:09:31 -0800 (PST) (envelope-from jhb@FreeBSD.org) Message-ID: X-Mailer: XFMail 1.4.0 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <20001129142056.A97794@inet.it> Date: Wed, 29 Nov 2000 09:09:48 -0800 (PST) From: John Baldwin To: Andrea Campi Subject: Re: [jhb@FreeBSD.org: RE: Panic in -current] Cc: freebsd-current@FreeBSD.org Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On 29-Nov-00 Andrea Campi wrote: >> >> We want mtxd_file and mtxd_line. If you look at the output of the last >> command, it will probably look something like this: > > ../../kern/kern_timeout.c, line 139 Hmm, and the failed assertion was: panic: mutex Giant owned at ../../kern/kern_intr.c:238 So it looks like we aren't releasing Giant, or that one of the callouts we called is getting giant but not releasing it. In sys/kern/kern_timeout.c, add in this: (at around line 139) if (!(c_flags & CALLOUT_MPSAFE)) mtx_enter(&Giant, MTX_DEF); splx(s); c_func(c_arg); s = splhigh(); if (!(c_flags & CALLOUT_MPSAFE)) mtx_exit(&Giant, MTX_DEF); /* add if statement below this */ if (mtx_owned(&Giant)) { printf("Bad callout handler: c_func = %p, c_arg = %p, c_flags = %d\n", c_func, c_arg, c_flags); panic("bad callout"); } Then when it panics write down the values that get printed out. Next, do 'nm /sys/compile/MYKERNEL/kernel.debug | sort' and look for the function whose address matches the c_func address printed out, then send this info back please. :) > Hope it helps, > Andrea -- John Baldwin -- http://www.FreeBSD.org/~jhb/ PGP Key: http://www.baldwin.cx/~john/pgpkey.asc "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message