Lines Matching full:lvp
83 struct vnode *dvp, *udvp, *ldvp, *vp, *uvp, *lvp, *dtmpvp; in unionfs_lookup() local
102 vp = uvp = lvp = NULLVP; in unionfs_lookup()
219 lerror = VOP_LOOKUP(ldvp, &lvp, &lcn); in unionfs_lookup()
222 if (lvp != NULLVP) in unionfs_lookup()
223 VOP_UNLOCK(lvp); in unionfs_lookup()
232 if (ldvp == lvp) { /* is dot */ in unionfs_lookup()
233 vrele(lvp); in unionfs_lookup()
238 } else if (lvp != NULLVP) in unionfs_lookup()
239 VOP_UNLOCK(lvp); in unionfs_lookup()
270 if (lvp != NULLVP) in unionfs_lookup()
271 vrele(lvp); in unionfs_lookup()
290 if (iswhiteout && lvp != NULLVP) { in unionfs_lookup()
291 vrele(lvp); in unionfs_lookup()
292 lvp = NULLVP; in unionfs_lookup()
305 if (uvp == NULLVP && lvp == NULLVP) { in unionfs_lookup()
313 if (uvp != NULLVP && lvp != NULLVP && uvp->v_type != lvp->v_type) { in unionfs_lookup()
314 vrele(lvp); in unionfs_lookup()
315 lvp = NULLVP; in unionfs_lookup()
322 lerror == 0 && lvp != NULLVP && lvp->v_type == VDIR && in unionfs_lookup()
326 error = unionfs_nodeget(dvp->v_mount, NULLVP, lvp, dvp, &vp, in unionfs_lookup()
370 error = unionfs_nodeget(dvp->v_mount, uvp, lvp, in unionfs_lookup()
393 if (lvp != NULLVP) in unionfs_lookup()
394 vrele(lvp); in unionfs_lookup()
581 struct vnode *lvp; in unionfs_lock_lvp() local
584 lvp = unp->un_lowervp; in unionfs_lock_lvp()
586 ASSERT_VOP_UNLOCKED(lvp, __func__); in unionfs_lock_lvp()
588 vref(lvp); in unionfs_lock_lvp()
590 vn_lock(lvp, *lkflags | LK_RETRY); in unionfs_lock_lvp()
591 if (VN_IS_DOOMED(lvp)) { in unionfs_lock_lvp()
592 vput(lvp); in unionfs_lock_lvp()
593 lvp = NULLVP; in unionfs_lock_lvp()
596 return (lvp); in unionfs_lock_lvp()
607 unionfs_unlock_lvp(struct vnode *vp, struct vnode *lvp, int lkflags) in unionfs_unlock_lvp() argument
609 ASSERT_VOP_LOCKED(lvp, __func__); in unionfs_unlock_lvp()
611 vput(lvp); in unionfs_unlock_lvp()
623 struct vnode *lvp; in unionfs_open() local
656 lvp = unp->un_lowervp; in unionfs_open()
664 targetvp = lvp; in unionfs_open()
666 if (targetvp == lvp && in unionfs_open()
667 (ap->a_mode & FWRITE) && lvp->v_type == VREG) in unionfs_open()
672 if ((ap->a_mode & FWRITE) && lvp->v_type == VREG) { in unionfs_open()
681 targetvp = lvp; in unionfs_open()
686 if (targetvp == uvp && uvp->v_type == VDIR && lvp != NULLVP && in unionfs_open()
689 else if (targetvp == lvp && uvp != NULLVP) in unionfs_open()
694 lvp = unionfs_lock_lvp(vp, &lkflags); in unionfs_open()
695 if (lvp == NULLVP) { in unionfs_open()
705 unp = unionfs_unlock_lvp(vp, lvp, lkflags); in unionfs_open()
717 lvp = unionfs_lock_lvp(vp, &lkflags); in unionfs_open()
718 if (lvp == NULLVP) { in unionfs_open()
723 error = VOP_OPEN(lvp, FREAD, cred, td, NULL); in unionfs_open()
724 unp = unionfs_unlock_lvp(vp, lvp, lkflags); in unionfs_open()
768 struct vnode *lvp; in unionfs_close() local
794 lvp = unp->un_lowervp; in unionfs_close()
807 ovp = lvp; in unionfs_close()
811 ovp = lvp; in unionfs_close()
813 if (ovp == lvp && uvp != NULLVP) { in unionfs_close()
816 lvp = unionfs_lock_lvp(vp, &lkflags); in unionfs_close()
817 if (lvp == NULLVP) { in unionfs_close()
827 unp = unionfs_unlock_lvp(vp, lvp, lkflags); in unionfs_close()
842 lvp = unionfs_lock_lvp(vp, &lkflags); in unionfs_close()
843 if (lvp == NULLVP) { in unionfs_close()
847 VOP_CLOSE(lvp, FREAD, cred, td); in unionfs_close()
848 unp = unionfs_unlock_lvp(vp, lvp, lkflags); in unionfs_close()
857 vp->v_object = lvp->v_object; in unionfs_close()
930 struct vnode *lvp; in unionfs_access() local
943 lvp = unp->un_lowervp; in unionfs_access()
968 if (lvp != NULLVP) { in unionfs_access()
984 lvp, &va, ap->a_cred, td); in unionfs_access()
997 error = VOP_ACCESS(lvp, accmode, ap->a_cred, td); in unionfs_access()
1011 struct vnode *lvp; in unionfs_getattr() local
1023 lvp = unp->un_lowervp; in unionfs_getattr()
1039 error = VOP_GETATTR(lvp, ap->a_vap, ap->a_cred); in unionfs_getattr()
1066 struct vnode *lvp; in unionfs_setattr() local
1078 lvp = unp->un_lowervp; in unionfs_setattr()
1088 if (uvp == NULLVP && lvp->v_type == VREG) { in unionfs_setattr()
1247 struct vnode *lvp; in unionfs_remove() local
1267 lvp = unp->un_lowervp; in unionfs_remove()
1277 lvp != NULLVP) in unionfs_remove()
1284 } else if (lvp != NULLVP) { in unionfs_remove()
1672 struct vnode *lvp; in unionfs_rmdir() local
1687 lvp = unp->un_lowervp; in unionfs_rmdir()
1696 if (lvp != NULLVP) { in unionfs_rmdir()
1706 * acquire lvp's lock in the normal fashion to reduce in unionfs_rmdir()
1712 if (vn_lock(lvp, LK_SHARED | LK_NOWAIT) != 0) { in unionfs_rmdir()
1715 vn_lock(lvp, LK_SHARED | LK_RETRY); in unionfs_rmdir()
1716 VOP_UNLOCK(lvp); in unionfs_rmdir()
1727 * LOR if we kept lvp locked across that call. in unionfs_rmdir()
1729 VOP_UNLOCK(lvp); in unionfs_rmdir()
1734 if (ump->um_whitemode == UNIONFS_WHITE_ALWAYS || lvp != NULLVP) in unionfs_rmdir()
1742 } else if (lvp != NULLVP) { in unionfs_rmdir()
1811 struct vnode *lvp; in unionfs_readdir() local
1832 lvp = NULLVP; in unionfs_readdir()
1851 lvp = unp->un_lowervp; in unionfs_readdir()
1855 (lvp != NULLVP && unsp->uns_lower_opencnt <= 0)) { in unionfs_readdir()
1865 if (uvp != NULLVP && lvp != NULLVP) { in unionfs_readdir()
1869 lvp = NULLVP; in unionfs_readdir()
1873 if (uvp != NULLVP && lvp == NULLVP) { in unionfs_readdir()
1886 if (uvp == NULLVP && lvp != NULLVP) { in unionfs_readdir()
1887 unionfs_forward_vop_start(lvp, &lkflags); in unionfs_readdir()
1888 error = VOP_READDIR(lvp, uio, ap->a_cred, ap->a_eofflag, in unionfs_readdir()
1890 if (unionfs_forward_vop_finish(vp, lvp, lkflags)) in unionfs_readdir()
1902 KASSERT(lvp != NULLVP, ("unionfs_readdir: null lower vp")); in unionfs_readdir()
1952 lvp = unionfs_lock_lvp(vp, &lkflags); in unionfs_readdir()
1953 if (lvp == NULL) { in unionfs_readdir()
1959 error = VOP_READDIR(lvp, uio, ap->a_cred, ap->a_eofflag, in unionfs_readdir()
1963 unp = unionfs_unlock_lvp(vp, lvp, lkflags); in unionfs_readdir()
2201 * access it because we currently hold lvp's lock. in unionfs_lock()
2202 * unionfs_noderem() acquires lvp's lock before freeing in unionfs_lock()
2205 * unionfs_node_update() acquires lvp's lock before installing in unionfs_lock()
2208 * Note that unionfs_noderem() doesn't acquire lvp's lock if in unionfs_lock()
2381 struct vnode *lvp; in unionfs_setacl() local
2392 lvp = unp->un_lowervp; in unionfs_setacl()
2398 if (uvp == NULLVP && lvp->v_type == VREG) { in unionfs_setacl()
2539 struct vnode *lvp; in unionfs_setextattr() local
2550 lvp = unp->un_lowervp; in unionfs_setextattr()
2569 if (ovp == lvp && lvp->v_type == VREG) { in unionfs_setextattr()
2570 VOP_CLOSEEXTATTR(lvp, 0, cred, td); in unionfs_setextattr()
2576 VOP_OPENEXTATTR(lvp, cred, td)) { in unionfs_setextattr()
2634 struct vnode *lvp; in unionfs_deleteextattr() local
2645 lvp = unp->un_lowervp; in unionfs_deleteextattr()
2664 if (ovp == lvp && lvp->v_type == VREG) { in unionfs_deleteextattr()
2665 VOP_CLOSEEXTATTR(lvp, 0, cred, td); in unionfs_deleteextattr()
2671 VOP_OPENEXTATTR(lvp, cred, td)) { in unionfs_deleteextattr()
2702 struct vnode *lvp; in unionfs_setlabel() local
2713 lvp = unp->un_lowervp; in unionfs_setlabel()
2719 if (uvp == NULLVP && lvp->v_type == VREG) { in unionfs_setlabel()
2772 struct vnode *dvp, *vp, **vpp, *lvp, *uvp, *tvp, *tdvp, *tempvp; in unionfs_vput_pair() local
2779 lvp = NULLVP; in unionfs_vput_pair()
2804 lvp = unp->un_lowervp; in unionfs_vput_pair()
2808 tvp = lvp; in unionfs_vput_pair()
2822 if (lvp != NULLVP) in unionfs_vput_pair()
2823 vhold(lvp); in unionfs_vput_pair()
2832 if (tdvp == dunp->un_uppervp && tvp != NULLVP && tvp == lvp) { in unionfs_vput_pair()
2861 error = unionfs_nodeget(mp, uvp, lvp, dvp, &tempvp, NULL); in unionfs_vput_pair()
2869 if (lvp != NULLVP) in unionfs_vput_pair()
2870 vdrop(lvp); in unionfs_vput_pair()
2887 * We assume text refs are managed against lvp/uvp through the in unionfs_set_text()