/freebsd/crypto/heimdal/lib/krb5/ |
H A D | aes-test.c | 327 krb5_crypto_iov iov[4]; in krb_enc_iov2() local 336 iov[0].flags = KRB5_CRYPTO_TYPE_HEADER; in krb_enc_iov2() 337 krb5_crypto_length(context, crypto, iov[0].flags, &iov[0].data.length); in krb_enc_iov2() 338 iov[0].data.data = emalloc(iov[0].data.length); in krb_enc_iov2() 340 iov[1].flags = KRB5_CRYPTO_TYPE_DATA; in krb_enc_iov2() 341 iov[1].data.length = len; in krb_enc_iov2() 342 iov[1].data.data = emalloc(iov[1].data.length); in krb_enc_iov2() 343 memcpy(iov[1].data.data, p, iov[1].data.length); in krb_enc_iov2() 346 iov[2].flags = KRB5_CRYPTO_TYPE_PADDING; in krb_enc_iov2() 347 krb5_crypto_length(context, crypto, KRB5_CRYPTO_TYPE_PADDING, &iov[2].data.length); in krb_enc_iov2() [all …]
|
/freebsd/sys/dev/pci/ |
H A D | pci_iov.c | 85 pci_read_config((d)->cfg.dev, (d)->cfg.iov->iov_pos + r, w) 88 pci_write_config((d)->cfg.dev, (d)->cfg.iov->iov_pos + r, v, w) 119 struct pcicfg_iov *iov; in pci_iov_attach_method() local 143 iov = malloc(sizeof(*dinfo->cfg.iov), M_SRIOV, M_WAITOK | M_ZERO); in pci_iov_attach_method() 146 if (dinfo->cfg.iov != NULL) { in pci_iov_attach_method() 150 iov->iov_pf = dev; in pci_iov_attach_method() 151 iov->iov_pos = iov_pos; in pci_iov_attach_method() 162 iov->iov_schema = schema; in pci_iov_attach_method() 164 iov->iov_cdev = make_dev(&iov_cdevsw, device_get_unit(dev), in pci_iov_attach_method() 167 if (iov->iov_cdev == NULL) { in pci_iov_attach_method() [all …]
|
/freebsd/lib/libsdp/ |
H A D | service.c | 52 struct iovec iov[4]; in sdp_register_service() local 74 iov[0].iov_base = (void *) &pdu; in sdp_register_service() 75 iov[0].iov_len = sizeof(pdu); in sdp_register_service() 77 iov[1].iov_base = (void *) &uuid; in sdp_register_service() 78 iov[1].iov_len = sizeof(uuid); in sdp_register_service() 80 iov[2].iov_base = (void *) bdaddr; in sdp_register_service() 81 iov[2].iov_len = sizeof(*bdaddr); in sdp_register_service() 83 iov[3].iov_base = (void *) data; in sdp_register_service() 84 iov[3].iov_len = datalen; in sdp_register_service() 87 len = writev(ss->s, iov, sizeof(iov)/sizeof(iov[0])); in sdp_register_service() [all …]
|
/freebsd/sys/contrib/openzfs/lib/libzfs/os/freebsd/ |
H A D | libzfs_zmount.c | 46 build_iovec(struct iovec **iov, int *iovlen, const char *name, void *val, in build_iovec() argument 54 *iov = realloc(*iov, sizeof (**iov) * (i + 2)); in build_iovec() 55 if (*iov == NULL) { in build_iovec() 59 (*iov)[i].iov_base = strdup(name); in build_iovec() 60 (*iov)[i].iov_len = strlen(name) + 1; in build_iovec() 62 (*iov)[i].iov_base = val; in build_iovec() 69 (*iov)[i].iov_len = (int)len; in build_iovec() 76 struct iovec *iov; in do_mount() local 88 iov = NULL; in do_mount() 91 build_iovec(&iov, &iovlen, "update", NULL, 0); in do_mount() [all …]
|
/freebsd/sbin/mount_msdosfs/ |
H A D | mount_msdosfs.c | 62 static int set_charset(struct iovec **iov, int *iovlen, const char *, const char *); 67 struct iovec *iov = NULL; in main() local 85 build_iovec(&iov, &iovlen, "shortnames", NULL, (size_t)-1); in main() 88 build_iovec(&iov, &iovlen, "longnames", NULL, (size_t)-1); in main() 91 build_iovec_argf(&iov, &iovlen, "nowin95", "", (size_t)-1); in main() 117 build_iovec_argf(&iov, &iovlen, "cs_local", quirk); in main() 123 build_iovec_argf(&iov, &iovlen, "cs_dos", cs_dos, (size_t)-1); in main() 134 build_iovec(&iov, &iovlen, optarg, val, (size_t)-1); in main() 153 build_iovec(&iov, &iovlen, "cs_local", cs_local, (size_t)-1); in main() 154 build_iovec(&iov, &iovlen, "cs_dos", cs_dos, (size_t)-1); in main() [all …]
|
/freebsd/sbin/mount/ |
H A D | getmntopts.c | 204 struct iovec *iov; variable 220 iov = NULL; 223 build_iovec(&iov, &iovlen, "fstype", __DECONST(void *, "ffs"), 4); 224 build_iovec(&iov, &iovlen, "from", mntp->f_mntfromname, (size_t)-1); 225 build_iovec(&iov, &iovlen, "fspath", mntp->f_mntonname, (size_t)-1); 226 build_iovec(&iov, &iovlen, "errmsg", errmsg, sizeof(errmsg)); 227 build_iovec(&iov, &iovlen, "update", NULL, 0); 228 build_iovec(&iov, &iovlen, "reload", NULL, 0); 233 build_iovec(&iov, &iovlen, "ro", NULL, 0); 234 error = nmount(iov, iovlen, mntp->f_flags); [all …]
|
/freebsd/contrib/netbsd-tests/net/bpf/ |
H A D | t_bpf.c | 110 struct iovec *iov; in ATF_TC_BODY() local 126 iov = calloc(iov_max, sizeof(struct iovec)); in ATF_TC_BODY() 127 ATF_REQUIRE(iov != NULL); in ATF_TC_BODY() 131 iov[0].iov_len = sz; in ATF_TC_BODY() 132 iov[0].iov_base = mmap(NULL, sz, PROT_READ, MAP_ANON, -1, 0); in ATF_TC_BODY() 133 ATF_REQUIRE(iov[0].iov_base != MAP_FAILED); in ATF_TC_BODY() 136 while (sz + iov[0].iov_len <= total) in ATF_TC_BODY() 138 iov[iovlen].iov_len = iov[0].iov_len; in ATF_TC_BODY() 139 iov[iovlen].iov_base = iov[0].iov_base; in ATF_TC_BODY() 140 sz += iov[0].iov_len; in ATF_TC_BODY() [all …]
|
/freebsd/sys/kern/ |
H A D | subr_uio.c | 97 struct iovec iov[1]; in physcopyin() local 101 iov[0].iov_base = src; in physcopyin() 102 iov[0].iov_len = len; in physcopyin() 103 uio.uio_iov = iov; in physcopyin() 118 struct iovec iov[1]; in physcopyout() local 122 iov[0].iov_base = dst; in physcopyout() 123 iov[0].iov_len = len; in physcopyout() 124 uio.uio_iov = iov; in physcopyout() 206 struct iovec *iov; in uiomove_faultflag() local 239 iov = uio->uio_iov; in uiomove_faultflag() [all …]
|
/freebsd/usr.sbin/bhyve/ |
H A D | iov.c | 70 count_iov(const struct iovec *iov, int niov) in count_iov() argument 76 total += iov[i].iov_len; in count_iov() 82 truncate_iov(struct iovec *iov, int *niov, size_t length) in truncate_iov() argument 88 size_t toseek = MIN(length - done, iov[i].iov_len); in truncate_iov() 91 if (toseek <= iov[i].iov_len) { in truncate_iov() 92 iov[i].iov_len = toseek; in truncate_iov() 100 iov_to_buf(const struct iovec *iov, int niov, void **buf) in iov_to_buf() argument 105 total = count_iov(iov, niov); in iov_to_buf() 111 memcpy((uint8_t *)*buf + ptr, iov[i].iov_base, iov[i].iov_len); in iov_to_buf() 112 ptr += iov[i].iov_len; in iov_to_buf() [all …]
|
/freebsd/sbin/mount_cd9660/ |
H A D | mount_cd9660.c | 76 struct iovec *iov; in main() local 84 iov = NULL; in main() 92 build_iovec(&iov, &iovlen, "brokenjoliet", NULL, (size_t)-1); in main() 95 build_iovec(&iov, &iovlen, "extatt", NULL, (size_t)-1); in main() 98 build_iovec(&iov, &iovlen, "gens", NULL, (size_t)-1); in main() 101 build_iovec_argf(&iov, &iovlen, "gid", "%d", a_gid(optarg)); in main() 104 build_iovec_argf(&iov, &iovlen, "mask", "%u", a_mask(optarg)); in main() 107 build_iovec_argf(&iov, &iovlen, "dirmask", "%u", a_mask(optarg)); in main() 110 build_iovec(&iov, &iovlen, "nojoliet", NULL, (size_t)-1); in main() 120 build_iovec(&iov, &iovlen, optarg, val, (size_t)-1); in main() [all …]
|
/freebsd/lib/libc/tests/secure/ |
H A D | fortify_uio_test.c | 353 struct iovec iov[1]; in ATF_TC_BODY() local 355 iov[0].iov_base = __stack.__buf; in ATF_TC_BODY() 356 iov[0].iov_len = __len; in ATF_TC_BODY() 360 readv(STDIN_FILENO, iov, nitems(iov)); in ATF_TC_BODY() 377 struct iovec iov[1]; in ATF_TC_BODY() local 379 iov[0].iov_base = __stack.__buf; in ATF_TC_BODY() 380 iov[0].iov_len = __len; in ATF_TC_BODY() 384 readv(STDIN_FILENO, iov, nitems(iov)); in ATF_TC_BODY() 401 struct iovec iov[1]; in ATF_TC_BODY() local 404 iov[0].iov_base = __stack.__buf; in ATF_TC_BODY() [all …]
|
/freebsd/crypto/heimdal/lib/gssapi/mech/ |
H A D | gss_aeap.c | 52 gss_iov_buffer_desc *iov, in gss_wrap_iov() argument 64 if (iov == NULL && iov_count != 0) in gss_wrap_iov() 74 iov, iov_count); in gss_wrap_iov() 89 gss_iov_buffer_desc *iov, in gss_unwrap_iov() argument 103 if (iov == NULL && iov_count != 0) in gss_unwrap_iov() 113 iov, iov_count); in gss_unwrap_iov() 133 gss_iov_buffer_desc *iov, in gss_wrap_iov_length() argument 145 if (iov == NULL && iov_count != 0) in gss_wrap_iov_length() 155 iov, iov_count); in gss_wrap_iov_length() 167 gss_iov_buffer_desc *iov, in gss_release_iov_buffer() argument [all …]
|
/freebsd/crypto/heimdal/lib/gssapi/ |
H A D | test_context.c | 289 gss_iov_buffer_desc iov[6]; in wrapunwrap_iov() local 297 memset(&iov, 0, sizeof(iov)); in wrapunwrap_iov() 314 iov_len = sizeof(iov)/sizeof(iov[0]); in wrapunwrap_iov() 316 memset(iov, 0, sizeof(iov)); in wrapunwrap_iov() 318 iov[0].type = GSS_IOV_BUFFER_TYPE_HEADER | GSS_IOV_BUFFER_TYPE_FLAG_ALLOCATE; in wrapunwrap_iov() 321 iov[1].type = GSS_IOV_BUFFER_TYPE_SIGN_ONLY; in wrapunwrap_iov() 322 iov[1].buffer.length = header.length; in wrapunwrap_iov() 323 iov[1].buffer.value = header.data; in wrapunwrap_iov() 325 iov[1].type = GSS_IOV_BUFFER_TYPE_EMPTY; in wrapunwrap_iov() 326 iov[1].buffer.length = 0; in wrapunwrap_iov() [all …]
|
/freebsd/usr.bin/wall/ |
H A D | ttymsg.c | 56 ttymsg(struct iovec *iov, int iovcnt, const char *line, int tmout) in ttymsg() argument 94 left += iov[cnt].iov_len; in ttymsg() 97 wret = writev(fd, iov, iovcnt); in ttymsg() 102 if (iov != localiov) { in ttymsg() 103 bcopy(iov, localiov, in ttymsg() 105 iov = localiov; in ttymsg() 107 for (cnt = 0; (size_t)wret >= iov->iov_len; ++cnt) { in ttymsg() 108 wret -= iov->iov_len; in ttymsg() 109 ++iov; in ttymsg() 113 iov->iov_base = (char *)iov->iov_base + wret; in ttymsg() [all …]
|
/freebsd/lib/libnv/ |
H A D | msgio.c | 151 struct iovec iov; in cred_send() local 156 bzero(&iov, sizeof(iov)); in cred_send() 166 iov.iov_base = &dummy; in cred_send() 167 iov.iov_len = sizeof(dummy); in cred_send() 169 msg.msg_iov = &iov; in cred_send() 191 struct iovec iov; in cred_recv() local 196 bzero(&iov, sizeof(iov)); in cred_recv() 198 iov.iov_base = &dummy; in cred_recv() 199 iov.iov_len = sizeof(dummy); in cred_recv() 201 msg.msg_iov = &iov; in cred_recv() [all …]
|
/freebsd/contrib/sendmail/libmilter/ |
H A D | comm.c | 241 retry_writev(fd, iov, iovcnt, timeout) in retry_writev() argument 243 struct iovec *iov; 254 while (iovcnt > 0 && iov[0].iov_len == 0) 256 iov++; 280 n = writev(fd, iov, iovcnt); 291 if (iov[i].iov_len > (unsigned int) n) 293 iov[i].iov_base = (char *)iov[i].iov_base + n; 294 iov[i].iov_len -= (unsigned int) n; 297 n -= (int) iov[i].iov_len; 298 iov[i].iov_len = 0; [all …]
|
/freebsd/sbin/mount_nfs/ |
H A D | mount_nfs.c | 129 static int getnfsargs(char **, char **, struct iovec **iov, int *iovlen); 137 char **errstr, struct iovec **iov, int *iovlen); 144 struct iovec *iov; in main() local 153 iov = NULL; in main() 169 build_iovec(&iov, &iovlen, "readahead", optarg, (size_t)-1); in main() 176 build_iovec(&iov, &iovlen, "noconn", NULL, 0); in main() 181 build_iovec(&iov, &iovlen, "deadthresh", optarg, (size_t)-1); in main() 185 build_iovec(&iov, &iovlen, "dumbtimer", NULL, 0); in main() 193 build_iovec(&iov, &iovlen, "maxgroups", optarg, (size_t)-1); in main() 197 build_iovec(&iov, &iovlen, "readdirsize", optarg, (size_t)-1); in main() [all …]
|
/freebsd/usr.sbin/lpr/common_source/ |
H A D | rmjob.c | 303 struct iovec *iov; in rmremote() local 328 iov = malloc(niov * sizeof *iov); in rmremote() 329 if (iov == NULL) in rmremote() 331 iov[0].iov_base = "\5"; in rmremote() 332 iov[1].iov_base = pp->remote_queue; in rmremote() 333 iov[2].iov_base = " "; in rmremote() 334 iov[3].iov_base = all ? "-all" : person; in rmremote() 337 iov[elem].iov_base = " "; in rmremote() 338 iov[elem + 1].iov_base = user[i]; in rmremote() 343 asprintf((char **)&iov[elem].iov_base, " %d", requ[i]); in rmremote() [all …]
|
/freebsd/crypto/heimdal/appl/gssmask/ |
H A D | gssmask.c | 888 gss_iov_buffer_desc iov[6]; in HandleOP() local 901 memset(&iov, 0, sizeof(iov)); in HandleOP() 903 iov_len = sizeof(iov)/sizeof(iov[0]); in HandleOP() 908 iov[0].type = GSS_IOV_BUFFER_TYPE_HEADER | GSS_IOV_BUFFER_TYPE_FLAG_ALLOCATE; in HandleOP() 910 iov[1].type = GSS_IOV_BUFFER_TYPE_SIGN_ONLY; in HandleOP() 911 iov[1].buffer.length = header.length; in HandleOP() 912 iov[1].buffer.value = header.data; in HandleOP() 914 iov[1].type = GSS_IOV_BUFFER_TYPE_EMPTY; in HandleOP() 916 iov[2].type = GSS_IOV_BUFFER_TYPE_DATA; in HandleOP() 917 iov[2].buffer.length = token.length; in HandleOP() [all …]
|
/freebsd/sys/i386/i386/ |
H A D | uio_machdep.c | 60 struct iovec *iov; in uiomove_fromphys() local 80 iov = uio->uio_iov; in uiomove_fromphys() 81 cnt = iov->iov_len; in uiomove_fromphys() 99 error = copyout(cp, iov->iov_base, cnt); in uiomove_fromphys() 102 error = copyin(iov->iov_base, cp, cnt); in uiomove_fromphys() 114 bcopy(cp, iov->iov_base, cnt); in uiomove_fromphys() 117 bcopy(iov->iov_base, cp, cnt); in uiomove_fromphys() 126 iov->iov_base = (char *)iov->iov_base + cnt; in uiomove_fromphys() 127 iov->iov_len -= cnt; in uiomove_fromphys()
|
/freebsd/sys/powerpc/powerpc/ |
H A D | uio_machdep.c | 62 struct iovec *iov; in uiomove_fromphys() local 84 iov = uio->uio_iov; in uiomove_fromphys() 85 cnt = iov->iov_len; in uiomove_fromphys() 105 error = copyout(cp, iov->iov_base, cnt); in uiomove_fromphys() 108 error = copyin(iov->iov_base, cp, cnt); in uiomove_fromphys() 119 bcopy(cp, iov->iov_base, cnt); in uiomove_fromphys() 122 bcopy(iov->iov_base, cp, cnt); in uiomove_fromphys() 130 iov->iov_base = (char *)iov->iov_base + cnt; in uiomove_fromphys() 131 iov->iov_len -= cnt; in uiomove_fromphys()
|
/freebsd/sys/arm/arm/ |
H A D | uio_machdep.c | 60 struct iovec *iov; in uiomove_fromphys() local 81 iov = uio->uio_iov; in uiomove_fromphys() 82 cnt = iov->iov_len; in uiomove_fromphys() 99 error = copyout(cp, iov->iov_base, cnt); in uiomove_fromphys() 102 error = copyin(iov->iov_base, cp, cnt); in uiomove_fromphys() 113 bcopy(cp, iov->iov_base, cnt); in uiomove_fromphys() 116 bcopy(iov->iov_base, cp, cnt); in uiomove_fromphys() 124 iov->iov_base = (char *)iov->iov_base + cnt; in uiomove_fromphys() 125 iov->iov_len -= cnt; in uiomove_fromphys()
|
/freebsd/contrib/smbfs/mount_smbfs/ |
H A D | mount_smbfs.c | 74 struct iovec *iov; in main() local 91 iov = NULL; in main() 186 build_iovec(&iov, &iovlen, in main() 203 build_iovec(&iov, &iovlen, optarg, val, (size_t)-1); in main() 278 build_iovec(&iov, &iovlen, "fstype", strdup("smbfs"), -1); in main() 279 build_iovec(&iov, &iovlen, "fspath", mount_point, -1); in main() 280 build_iovec_argf(&iov, &iovlen, "fd", "%d", fd); in main() 281 build_iovec(&iov, &iovlen, "mountpoint", mount_point, -1); in main() 282 build_iovec_argf(&iov, &iovlen, "uid", "%d", uid); in main() 283 build_iovec_argf(&iov, &iovlen, "gid", "%d", gid); in main() [all …]
|
/freebsd/sys/riscv/riscv/ |
H A D | uio_machdep.c | 57 struct iovec *iov; in uiomove_fromphys() local 79 iov = uio->uio_iov; in uiomove_fromphys() 80 cnt = iov->iov_len; in uiomove_fromphys() 100 error = copyout(cp, iov->iov_base, cnt); in uiomove_fromphys() 103 error = copyin(iov->iov_base, cp, cnt); in uiomove_fromphys() 112 bcopy(cp, iov->iov_base, cnt); in uiomove_fromphys() 115 bcopy(iov->iov_base, cp, cnt); in uiomove_fromphys() 127 iov->iov_base = (char *)iov->iov_base + cnt; in uiomove_fromphys() 128 iov->iov_len -= cnt; in uiomove_fromphys()
|
/freebsd/sys/arm64/arm64/ |
H A D | uio_machdep.c | 57 struct iovec *iov; in uiomove_fromphys() local 79 iov = uio->uio_iov; in uiomove_fromphys() 80 cnt = iov->iov_len; in uiomove_fromphys() 100 error = copyout(cp, iov->iov_base, cnt); in uiomove_fromphys() 103 error = copyin(iov->iov_base, cp, cnt); in uiomove_fromphys() 112 bcopy(cp, iov->iov_base, cnt); in uiomove_fromphys() 115 bcopy(iov->iov_base, cp, cnt); in uiomove_fromphys() 127 iov->iov_base = (char *)iov->iov_base + cnt; in uiomove_fromphys() 128 iov->iov_len -= cnt; in uiomove_fromphys()
|