The use of VOP_ISLOCKED() without a check for the return values can cause
false positives. Replace the #ifdef block with the proper ASSERT_VOP_UNLOCKED() assert. Tested by: pho MFC after: 1 week
This commit is contained in:
parent
234ab7412e
commit
17edcd764d
@ -242,10 +242,7 @@ nullfs_root(mp, flags, vpp)
|
||||
vp = MOUNTTONULLMOUNT(mp)->nullm_rootvp;
|
||||
VREF(vp);
|
||||
|
||||
#ifdef NULLFS_DEBUG
|
||||
if (VOP_ISLOCKED(vp))
|
||||
panic("root vnode is locked.\n");
|
||||
#endif
|
||||
ASSERT_VOP_UNLOCKED(vp, "root vnode is locked");
|
||||
vn_lock(vp, flags | LK_RETRY);
|
||||
*vpp = vp;
|
||||
return 0;
|
||||
|
Loading…
Reference in New Issue
Block a user