HomeFreeBSD

unionfs: fixes to unionfs_nodeget() error handling

Description

unionfs: fixes to unionfs_nodeget() error handling

If either the lower or upper vnode is found to be doomed after
locking it, the newly-created unionfs node won't be associated
with it and its lock will be dropped. In that case, clear the
uppervp and lowervp locals as necessary to avoid further use
of the vnode in unionfs_nodeget(). If the upper vnode is doomed
but the lower vnode remains valid, additionally reset the unionfs
node's v_vnlock field to point to the lower vnode lock.

Reviewed by: kib, markj
Tested by: pho
Differential Revision: https://reviews.freebsd.org/D39767

Details

Provenance
jahAuthored on Mar 26 2023, 1:30 AM
Reviewer
kib
Differential Revision
D39767: Various fixes to unionfs error handling logic
Parents
rG95950880ade0: libc: document when the namespace was created
Branches
Unknown
Tags
Unknown