HomeFreeBSD

Allow realpath to work for file mounts

Description

Allow realpath to work for file mounts

For file mounts, the directory vnode is not available from namei and this
prevents the use of vn_fullpath_hardlink. In this case, we can use the
vnode which was covered by the file mount with vn_fullpath.

This also disallows file mounts over files with link counts greater than
one to ensure a deterministic path to the mount point.

Reviewed by: mjg, kib
Tested by: pho

(cherry picked from commit a1d74b2dab78d56582126b4944b435d00747f601)

Details

Provenance
dfrAuthored on Dec 4 2022, 3:53 PM
Parents
rGd373650a5397: Add support for mounting single files in nullfs
Branches
Unknown
Tags
Unknown