Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 2 Oct 2002 23:12:59 -0700 (PDT)
From:      Don Lewis <dl-freebsd@catspoiler.org>
To:        cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject:   Re: cvs commit: src/sys/kern kern_event.c
Message-ID:  <200210030613.g936CxvU017849@gw.catspoiler.org>
In-Reply-To: <200210030603.g9363QEx044482@freefall.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On  2 Oct, Don Lewis wrote:
> truckman    2002/10/02 23:03:26 PDT
> 
>   Modified files:
>     sys/kern             kern_event.c 
>   Log:
>   hashinit() calls MALLOC(), so release the filedesc lock in knote_attach()
>   before calling hashinit() and relock afterwards, taking care to see that
>   we don't lose a race.
>   
>   Revision  Changes    Path
>   1.46      +16 -4     src/sys/kern/kern_event.c

knote_attach() could use some cleanup.  It would be possible to get rid
of some extraneous unlocking and relocking if the calls to free() were
moved to the end and made conditional.  I'm not much of a fan of this
type of conditional code, but it is less costly than doing a bunch of
extra lock manipulation.


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200210030613.g936CxvU017849>