new dentry feature in 2.1.78

Bill Hawes (whawes@star.net)
Fri, 09 Jan 1998 15:29:57 -0500


Just wanted to mention that there's a new feature in the 2.1.78 dcache
that may be useful for some of the filesystems. It's a void * pointer to
a private area, initialized to NULL when the dentry is created but
otherwise unmolested for the life of the dentry.

Typically you would create your private data structure and install it in
d_fsdata in the fs lookup routine, or possibly in a d_hash routine. To
free it, you need to have a dentry_ops d_release operation, which is
then called at d_free time.

For examples take a look in nfs/dir.c. The d_fsdata area is now being
used to store the NFS filehandle in the dentry instead of in the inode.

Regards,
Bill