Lines Matching defs:flp
831 flock_check(vnode_t *vp, flock64_t *flp, offset_t offset, offset_t max)
840 switch (flp->l_whence) {
842 start = (u_offset_t)flp->l_start;
847 if (flp->l_start > (max - offset))
849 start = (u_offset_t)(flp->l_start + offset);
857 if (flp->l_start > (max - (offset_t)vattr.va_size))
859 start = (u_offset_t)(flp->l_start + (offset_t)vattr.va_size);
870 if (flp->l_len == 0)
872 else if ((offset_t)flp->l_len > 0) {
873 if (flp->l_len > (max - start + 1))
875 end = (u_offset_t)(start + (flp->l_len - 1));
884 start += (u_offset_t)flp->l_len;
891 if (flp->l_type == F_UNLCK && flp->l_len > 0 &&
893 flp->l_len = 0;
901 flock_get_start(vnode_t *vp, flock64_t *flp, offset_t offset, u_offset_t *start)
910 switch (flp->l_whence) {
912 *start = (u_offset_t)flp->l_start;
915 *start = (u_offset_t)(flp->l_start + offset);
921 *start = (u_offset_t)(flp->l_start + (offset_t)vattr.va_size);