Comment 72 for bug 769927

Revision history for this message
In , David (david-redhat-bugs) wrote :

I'd be very surprised if you saw the bug appearing in relation to the dentry attached to s_root. NFS's s_root dentry is a placeholder to stop the VFS blowing up, no more. It isn't actually used for anything.

As NFS may share superblocks between several disjoint mounts from the same remote filesystem, it keeps its roots in the s_anon list instead. Should the root of a mount be detected in the tree of another mount, then the two trees are spliced together at that point by d_materialise_unique(). The resulting tree will still have an anonymous root.

It is done this way as we may not have access to the actual root directory of the remote filesystem, and so may not be able to put that into our tree.

Thus the root of the mount is attached directly to the vfsmount struct without going anywhere near the core tree in the superblock.