Lines Matching refs:iov
71 count_iov(const struct iovec *iov, int niov) in count_iov() argument
77 total += iov[i].iov_len; in count_iov()
83 truncate_iov(struct iovec *iov, int *niov, size_t length) in truncate_iov() argument
89 size_t toseek = MIN(length - done, iov[i].iov_len); in truncate_iov()
92 if (toseek <= iov[i].iov_len) { in truncate_iov()
93 iov[i].iov_len = toseek; in truncate_iov()
101 iov_to_buf(const struct iovec *iov, int niov, void **buf) in iov_to_buf() argument
106 total = count_iov(iov, niov); in iov_to_buf()
112 memcpy((uint8_t *)*buf + ptr, iov[i].iov_base, iov[i].iov_len); in iov_to_buf()
113 ptr += iov[i].iov_len; in iov_to_buf()
120 buf_to_iov(const void *buf, size_t buflen, const struct iovec *iov, int niov, in buf_to_iov() argument
135 seek_iov(iov, niov, diov, &ndiov, seek); in buf_to_iov()
136 iov = diov; in buf_to_iov()
141 len = MIN(iov[i].iov_len, buflen - off); in buf_to_iov()
142 memcpy(iov[i].iov_base, (const uint8_t *)buf + off, len); in buf_to_iov()