Subject: Re: poolifying fileassoc
To: YAMAMOTO Takashi <yamt@mwd.biglobe.ne.jp>
From: Brett Lymn <blymn@baesystems.com.au>
List: tech-kern
Date: 10/04/2006 09:33:59
On Wed, Oct 04, 2006 at 12:39:28AM +0900, YAMAMOTO Takashi wrote:
>
> what's "vmlock"?
>
Sorry, my bad for being vague, I mean that I get a panic saying that a
simple lock is held if I have LOCKDEBUG defined. This panic seems to
be coming from malloc() when I try to use vfs_composefh_alloc() when I
try to perform a per page check during uvn_getpages(). From what I
can see this is not a bug - the LOCKDEBUG code is detecting something
that should not be done in that context. My thinking is that I need
to have some preallocated resources to avoid performing a malloc in
fileassoc_file_lookup(), to me using a pool looked like the correct
thing to do. I can then use this preallocated resource to provide
storage to vfs_composefh() to fill in the file handle for me. This
storage is only required during the fileassoc_lookup_file() call so
the number of preallocated structures should only need to be
relatively small.
--
Brett Lymn