Subject: Re: nullfs ihash locking?
To: Blair Sadewitz <blair.sadewitz@gmail.com>
From: Bill Stouder-Studenmund <wrstuden@netbsd.org>
List: current-users
Date: 06/01/2007 11:40:55
--u3/rZRmxL6MmkK24
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Mon, May 21, 2007 at 11:17:51PM -0400, Blair Sadewitz wrote:
> Would nullfs be subject to the same problem outlined in PR 36331?  I

Probably. I expect that the nullfs code was copied from the ffs/ufs code=20
way back when. And enhanced with locks in the same way.

> don't know much about the internals of genfs or how the layerfs stuff
> works, but I'm getting what appear to be deadlocks only when using
> mount_null.

layerfs is like genfs but it's only for layered file systems. Back when I=
=20
was adding the overlay fs, I noticed that nullfs and umapfs and overlayfs=
=20
and dmfs (the fs I was working on) all had large blocks of code that were=
=20
almost the same. So I created layerfs and made routines that all of them=20
could share.

Maintaining the hash table for vnodes was one thing that went into
layerfs. They all did almost the same thing. The only difference was a
little bit of work in node creation once we have a new node. Thus there's
a callback in the layerfs node cache code.

> If someone could clue me in, I'd appreciate it.

I hope the above helps.

Take care,

Bill

--u3/rZRmxL6MmkK24
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.3 (NetBSD)

iD8DBQFGYGg3Wz+3JHUci9cRAv0lAJ42tliyPWYFgD3w7kDm23XfVzupBgCfT8sX
Uz1Fsc8BTilZKAqbABZfR8k=
=bYJG
-----END PGP SIGNATURE-----

--u3/rZRmxL6MmkK24--