HomeFreeBSD

Fix NFS client vnode locking to avoid a crash during forced dismount.

Description

Fix NFS client vnode locking to avoid a crash during forced dismount.

A crash was reported where the crash occurred in nfs_advlock() when the
NFS_ISV4(vp) macro was being executed. This was caused by the vnode
being VI_DOOMED due to a forced dismount in progress.
This patch fixes the problem by locking the vnode before executing the
NFS_ISV4() macro.

Tested by: rlibby
PR: 232673
Reviewed by: kib
MFC after: 2 weeks
Differential Revision: https://reviews.freebsd.org/D17757

Details

Provenance
rmacklemAuthored on
Reviewer
kib
Differential Revision
D17757: fix NFS client advisory locking when a forced dismount is performed
Parents
rS339998: MFC r339661, r339669:
Branches
Unknown
Tags
Unknown