Subject: Re: VFS layer documentation
To: Matthias Scheler <tron@zhadum.de>
From: Bill Studenmund <wrstuden@netbsd.org>
List: tech-kern
Date: 05/25/2004 10:39:32
--3siQDZowHQqNOShm
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
On Tue, May 25, 2004 at 07:14:07PM +0200, Matthias Scheler wrote:
> On Tue, May 25, 2004 at 09:58:14AM -0700, Bill Studenmund wrote:
> > Is there something specific you were wondering about?
>=20
> I was wondering for what purposes VFS_MOUNT() is used. According to
> vfsops(9) is used for mounting and updating mount flags. But looking
> at the code of various of NetBSD's filesystem it appears also to
> be used for querying information.
Hmmm.... I'm not familiar with that usage. Oh, I see some of it is the=20
GETARGS usage. I guess Christos added that w/o documenting.
> And some documentation about the handling of NFS exports would be
I know some, but given the above, I'm not sure I know enough to help you.=
=20
The simple answer is that you use the mount system call to control who can=
=20
access the file system. VFS_MOUNT() turns that into a call to=20
vfs_export(). To turn a file handle into a vnode, VFS_FHTOVP(). Then to=20
check exports, VFS_CHECKEXP(). Note that fhopen(2) and friends also use=20
VFS_FHTOVP().
For the most part, NFS export issues are handled by vfs-common code that=20
the specific file system merely has to hook into.
Does that help any? I realize you might have already known that. :-)
Take care,
Bill
--3siQDZowHQqNOShm
Content-Type: application/pgp-signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (NetBSD)
iD8DBQFAs4TUWz+3JHUci9cRAtydAKCVDsYw+t6nLLar/GKCjI+7PQNoYACdHlux
NU5+Oec5/Kq5agUDZo6dMNQ=
=waSY
-----END PGP SIGNATURE-----
--3siQDZowHQqNOShm--