Tree-wide replacement of VOP_UNLOCK + vrele combo with vput

No functional changes.
This commit is contained in:
Mateusz Guzik 2022-11-07 23:33:15 +00:00
parent 613aaf59af
commit b935e867af
4 changed files with 8 additions and 16 deletions

View File

@ -812,8 +812,7 @@ loop:
error = bread(devvp, fsbtodb(fs, ino_to_fsba(fs, ip->i_number)),
(int)fs->e2fs_bsize, NOCRED, &bp);
if (error) {
VOP_UNLOCK(vp);
vrele(vp);
vput(vp);
MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp);
return (error);
}
@ -822,8 +821,7 @@ loop:
EXT2_INODE_SIZE(fs) * ino_to_fsbo(fs, ip->i_number)), ip);
brelse(bp);
VOP_UNLOCK(vp);
vrele(vp);
vput(vp);
if (error) {
MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp);
@ -1167,8 +1165,7 @@ loop:
}
if ((error = VOP_FSYNC(vp, waitfor, td)) != 0)
allerror = error;
VOP_UNLOCK(vp);
vrele(vp);
vput(vp);
}
/*

View File

@ -624,8 +624,7 @@ fuse_vfsop_root(struct mount *mp, int lkflags, struct vnode **vpp)
SDT_PROBE2(fusefs, , vfsops, trace, 1,
"root vnode race");
FUSE_UNLOCK();
VOP_UNLOCK(*vpp);
vrele(*vpp);
vput(*vpp);
vrecycle(*vpp);
*vpp = data->vroot;
} else

View File

@ -1041,8 +1041,7 @@ loop:
error = VOP_FSYNC(vp, waitfor, td);
if (error)
allerror = error;
VOP_UNLOCK(vp);
vrele(vp);
vput(vp);
}
/*

View File

@ -615,13 +615,11 @@ again:
goto again;
}
if (vp->v_type == VNON || vp->v_writecount <= 0) {
VOP_UNLOCK(vp);
vrele(vp);
vput(vp);
continue;
}
error = getinoquota(VTOI(vp));
VOP_UNLOCK(vp);
vrele(vp);
vput(vp);
if (error) {
MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp);
break;
@ -684,8 +682,7 @@ again:
dq = ip->i_dquot[type];
ip->i_dquot[type] = NODQUOT;
dqrele(vp, dq);
VOP_UNLOCK(vp);
vrele(vp);
vput(vp);
}
error = dqflush(qvp);