Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 14 Aug 2002 01:49:06 -0700
From:      Terry Lambert <tlambert2@mindspring.com>
To:        sjh@ucf.ics.uci.edu
Cc:        current@freebsd.org
Subject:   Re: bremfree: bp 0xc77938f4 not locked (Most recently used by kqueue)
Message-ID:  <3D5A1982.87B8C015@mindspring.com>
References:  <200208130533.g7D5Xql13446@whiskey.ucf.ics.uci.edu>

next in thread | previous in thread | raw e-mail | index | archive | help
Seth Hettich wrote:
> I get this all the time, and have for months now.  On two different
> systems (both updated to -current about 2 times per month), both
> PCs (but with greatly differing HW).
> 
> What would be my first step to resolve this?  I sent in a PR, with
> lots of notes, things I tried, and stack dumps.  I'm willing to do
> some more work on it, if someone can point me in the right direction.
> 
> panic: bremfree: bp 0xc77938f4 not locked
> panic messages:
> ---
> panic: Most recently used by kqueue


Having just finished documenting all of the kqueue code internals
for my own use, I can tell you exactly where this problem lies.

If you look at the kqueue code itself, in /sys/kern/kern_event.c,
you will see the function knote().

The knote() function is conceptually very simple; it iterates the
knote list hung off an object on which an event has just occurred,
and calls the function kn->kn_fop->f_event(kn, hint).

If you remember Julian's recent commit to the queue.h to make the
list iterators unsafe to do removes in (OK, technically, he didn't
make the change for that, it was just a very important undesirable
side effect 8-)), you will understand the problem.

-- Terry

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?3D5A1982.87B8C015>