xfs_dnlc_lookup

Assar Westerlund assar at sics.se
Thu Apr 2 03:28:26 CEST 1998


Cheng Jin <chengjin at eecs.umich.edu> writes:
> I am looking at xfs_dnlc_lookup function in xfs_node.c.  It calls
> cache_lookup to search the existing vnode cache, and after that it checks
> the vnode pointer stored in tbl.  Tbl seems to store the pointer to the
> most recently brought in vnode, which should also be in the vnode cache(?)
> 
> Why is tbl checked after cache_lookup then?  Is it trying to prevent two
> vnodes from being created when two simultaneous opens are done on the same
> file? would it be better to check tbl first then?

Only file names shorter than or equal to NCHNAMLEN characters are
stored in the name cache.  Because xfs depends on the name cache
working the tbl acts as a one-entry name-cache for longer names.

/assar





More information about the Arla-drinkers mailing list