HomeFreeBSD

nullfs: ensure correct lock is taken after bypass.

Description

nullfs: ensure correct lock is taken after bypass.

If lower VOP relocked the lower vnode, it is possible that nullfs
vnode was reclaimed meantime. In this case nullfs vnode no longer
shares lock with lower vnode, which breaks locking protocol.

Check for the condition and acquire nullfs vnode lock if detected.

Reported and tested by: pho
Sponsored by: The FreeBSD Foundation
MFC after: 1 week

Details

Provenance
kibAuthored on
Parents
rS366848: vgonel(): avoid recursing into VOP_INACTIVE().
Branches
Unknown
Tags
Unknown