Date: Tue, 04 Mar 2003 13:45:05 -0500 (EST) From: John Baldwin <jhb@FreeBSD.org> To: Andrew Gallatin <gallatin@cs.duke.edu> Cc: freebsd-current@freebsd.org Subject: RE: witness_get: witness exhausted? Message-ID: <XFMail.20030304134505.jhb@FreeBSD.org> In-Reply-To: <15971.59141.326652.334367@grasshopper.cs.duke.edu>
next in thread | previous in thread | raw e-mail | index | archive | help
On 03-Mar-2003 Andrew Gallatin wrote: > > I'm developing a character driver which tracks a lot of state on a > per-open basis. I've got several mutexes in there which are > initialzed at open, and destroyed at close. After a few > dozen opens, witness seems to croak with: > > witness_get: witness exhausted > > Am I leaking something? Or is the witness code? I looked at > subr_witness.c, and I don't see witness_free() being called from > witness_destroy(). There's probably some design constraint that > I don't understand. Unfortunately dead witnesses may still be stuck in the lock order hierarchy and I haven't figured out yet how to properly handle the case of free'ing a witness structure from the tree while preserving the correct lock orders. You can try http://www.freebsd.org/~jhb/patches/witness.patch but I don't think it will help with your specific case. > FWIW, Witness (and the FreeBSD debugging environment in general) is > why I've gotten approval to co-develop this driver on FreeBSD (in > addition to linux). Its already caught several locking bugs. Glad to hear it is at least working in some cases. :) -- John Baldwin <jhb@FreeBSD.org> <>< http://www.FreeBSD.org/~jhb/ "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
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?XFMail.20030304134505.jhb>
