Lines Matching refs:nr_segs

119 			i->nr_segs -= iov - i->iov;		\
127 i->nr_segs -= bvec - i->bvec; \
135 i->nr_segs -= kvec - i->kvec; \
249 i->nr_segs -= iov - i->iov; in copy_page_to_iter_iovec()
333 i->nr_segs -= iov - i->iov; in copy_page_from_iter_iovec()
509 const struct iovec *iov, unsigned long nr_segs, in iov_iter_init() argument
518 .nr_segs = nr_segs, in iov_iter_init()
1047 i->nr_segs -= bi.bi_idx; in iov_iter_bvec_advance()
1061 for (iov = i->iov, end = iov + i->nr_segs; iov < end; iov++) { in iov_iter_iovec_advance()
1067 i->nr_segs -= iov - i->iov; in iov_iter_iovec_advance()
1140 i->nr_segs++; in iov_iter_revert()
1152 i->nr_segs++; in iov_iter_revert()
1169 if (i->nr_segs > 1) { in iov_iter_single_seg_count()
1180 const struct kvec *kvec, unsigned long nr_segs, in iov_iter_kvec() argument
1188 .nr_segs = nr_segs, in iov_iter_kvec()
1196 const struct bio_vec *bvec, unsigned long nr_segs, in iov_iter_bvec() argument
1204 .nr_segs = nr_segs, in iov_iter_bvec()
1285 for (k = 0; k < i->nr_segs; k++, skip = 0) { in iov_iter_alignment_iovec()
1307 for (k = 0; k < i->nr_segs; k++, skip = 0) { in iov_iter_alignment_bvec()
1355 for (k = 0; k < i->nr_segs; k++) { in iov_iter_gap_alignment()
1482 for (k = 0, skip = i->iov_offset; k < i->nr_segs; k++, skip = 0) { in first_iovec_segment()
1843 new->nr_segs * sizeof(struct bio_vec), in dup_iter()
1848 new->nr_segs * sizeof(struct iovec), in dup_iter()
1854 const struct iovec __user *uvec, unsigned long nr_segs) in copy_compat_iovec_from_user() argument
1860 if (!user_access_begin(uiov, nr_segs * sizeof(*uiov))) in copy_compat_iovec_from_user()
1863 for (i = 0; i < nr_segs; i++) { in copy_compat_iovec_from_user()
1886 const struct iovec __user *uvec, unsigned long nr_segs) in copy_iovec_from_user() argument
1890 if (copy_from_user(iov, uvec, nr_segs * sizeof(*uvec))) in copy_iovec_from_user()
1892 for (seg = 0; seg < nr_segs; seg++) { in copy_iovec_from_user()
1901 unsigned long nr_segs, unsigned long fast_segs, in iovec_from_user() argument
1912 if (nr_segs == 0) in iovec_from_user()
1914 if (nr_segs > UIO_MAXIOV) in iovec_from_user()
1916 if (nr_segs > fast_segs) { in iovec_from_user()
1917 iov = kmalloc_array(nr_segs, sizeof(struct iovec), GFP_KERNEL); in iovec_from_user()
1923 ret = copy_compat_iovec_from_user(iov, uvec, nr_segs); in iovec_from_user()
1925 ret = copy_iovec_from_user(iov, uvec, nr_segs); in iovec_from_user()
1936 unsigned nr_segs, unsigned fast_segs, struct iovec **iovp, in __import_iovec() argument
1943 iov = iovec_from_user(uvec, nr_segs, fast_segs, *iovp, compat); in __import_iovec()
1957 for (seg = 0; seg < nr_segs; seg++) { in __import_iovec()
1974 iov_iter_init(i, type, iov, nr_segs, total_len); in __import_iovec()
2005 unsigned nr_segs, unsigned fast_segs, in import_iovec() argument
2008 return __import_iovec(type, uvec, nr_segs, fast_segs, iovp, i, in import_iovec()
2058 i->bvec -= state->nr_segs - i->nr_segs; in iov_iter_restore()
2060 i->iov -= state->nr_segs - i->nr_segs; in iov_iter_restore()
2061 i->nr_segs = state->nr_segs; in iov_iter_restore()