/freebsd/sys/powerpc/powerpc/ |
H A D | busdma_machdep.c | 474 bus_size_t buflen, int flags) in _bus_dmamap_count_phys() argument 489 while (buflen != 0) { in _bus_dmamap_count_phys() 490 sgsize = buflen; in _bus_dmamap_count_phys() 497 buflen -= sgsize; in _bus_dmamap_count_phys() 521 vendaddr = (vm_offset_t)buf + buflen; in _bus_dmamap_count_pages() 570 while (buflen > 0) { in _bus_dmamap_load_phys() 572 sgsize = buflen; in _bus_dmamap_load_phys() 582 buflen -= sgsize; in _bus_dmamap_load_phys() 608 void *buf, bus_size_t buflen, in _bus_dmamap_load_buffer() argument 633 while (buflen > 0) { in _bus_dmamap_load_buffer() [all …]
|
/freebsd/contrib/unifdef/win32/ |
H A D | win32.c | 62 int c99_snprintf(char *buf, size_t buflen, const char *format, ...) in c99_snprintf() argument 71 if (buflen == 0 || outlen < 0) in c99_snprintf() 73 if (buflen > outlen) in c99_snprintf() 76 cpylen = buflen - 1; in c99_snprintf()
|
/freebsd/sys/contrib/dev/iwlwifi/fw/ |
H A D | debugfs.c | 12 #define FWRT_DEBUGFS_OPEN_WRAPPER(name, buflen, argtype) \ argument 17 char rbuf[buflen]; \ 62 #define _FWRT_DEBUGFS_READ_FILE_OPS(name, buflen, argtype) \ argument 63 FWRT_DEBUGFS_OPEN_WRAPPER(name, buflen, argtype) \ 72 #define FWRT_DEBUGFS_WRITE_WRAPPER(name, buflen, argtype) \ argument 79 char buf[buflen] = {}; \ 89 FWRT_DEBUGFS_OPEN_WRAPPER(name, buflen, argtype) \ 90 FWRT_DEBUGFS_WRITE_WRAPPER(name, buflen, argtype) \ 100 #define _FWRT_DEBUGFS_WRITE_FILE_OPS(name, buflen, argtype) \ argument 101 FWRT_DEBUGFS_OPEN_WRAPPER(name, buflen, argtype) \ [all …]
|
/freebsd/lib/libc/net/ |
H A D | getnetbyht.c | 146 getnetent_r(struct netent *nptr, char *buffer, size_t buflen, in getnetent_r() argument 161 if (__copy_netent(&ne, nptr, buffer, buflen) != 0) { in getnetent_r() 190 size_t buflen; in _ht_getnetbyname() local 201 buflen = va_arg(ap, size_t); in _ht_getnetbyname() 227 if (__copy_netent(&ne, nptr, buffer, buflen) != 0) { in _ht_getnetbyname() 243 size_t buflen; in _ht_getnetbyaddr() local 254 buflen = va_arg(ap, size_t); in _ht_getnetbyaddr() 275 if (__copy_netent(&ne, nptr, buffer, buflen) != 0) { in _ht_getnetbyaddr()
|
H A D | getprotoname.c | 64 size_t buflen; in files_getprotobyname() local 70 buflen = va_arg(ap, size_t); in files_getprotobyname() 94 if (__copy_protoent(&pe, pptr, buffer, buflen) != 0) { in files_getprotobyname() 106 size_t buflen, struct protoent **result) in getprotobyname_r() argument 126 defaultsrc, name, pptr, buffer, buflen, &ret_errno); in getprotobyname_r()
|
/freebsd/tests/sys/kern/pipe/ |
H A D | big_pipe_test.c | 18 write_frame(int fd, char *buf, unsigned long buflen) in write_frame() argument 23 while (buflen) { in write_frame() 33 i = write(fd, buf, buflen); in write_frame() 40 buflen -= i; in write_frame()
|
/freebsd/sys/contrib/libsodium/src/libsodium/crypto_generichash/blake2b/ref/ |
H A D | blake2b-ref.c | 264 size_t left = S->buflen; in blake2b_update() 269 S->buflen += fill; in blake2b_update() 274 S->buflen -= BLAKE2B_BLOCKBYTES; in blake2b_update() 280 S->buflen += inlen; /* Be lazy, do not compress */ in blake2b_update() 300 if (S->buflen > BLAKE2B_BLOCKBYTES) { in blake2b_final() 303 S->buflen -= BLAKE2B_BLOCKBYTES; in blake2b_final() 304 assert(S->buflen <= BLAKE2B_BLOCKBYTES); in blake2b_final() 305 memcpy(S->buf, S->buf + BLAKE2B_BLOCKBYTES, S->buflen); in blake2b_final() 308 blake2b_increment_counter(S, S->buflen); in blake2b_final() 310 memset(S->buf + S->buflen, 0, in blake2b_final() [all …]
|
/freebsd/crypto/openssl/providers/implementations/digests/ |
H A D | blake2b_prov.c | 271 fill = sizeof(c->buf) - c->buflen; in ossl_blake2b_update() 273 if (c->buflen) { in ossl_blake2b_update() 274 memcpy(c->buf + c->buflen, in, fill); /* Fill buffer */ in ossl_blake2b_update() 276 c->buflen = 0; in ossl_blake2b_update() 296 memcpy(c->buf + c->buflen, in, datalen); in ossl_blake2b_update() 297 c->buflen += datalen; /* Be lazy, do not compress */ in ossl_blake2b_update() 319 memset(c->buf + c->buflen, 0, sizeof(c->buf) - c->buflen); in ossl_blake2b_final() 320 blake2b_compress(c, c->buf, c->buflen); in ossl_blake2b_final()
|
H A D | blake2s_prov.c | 262 fill = sizeof(c->buf) - c->buflen; in ossl_blake2s_update() 264 if (c->buflen) { in ossl_blake2s_update() 265 memcpy(c->buf + c->buflen, in, fill); /* Fill buffer */ in ossl_blake2s_update() 267 c->buflen = 0; in ossl_blake2s_update() 287 memcpy(c->buf + c->buflen, in, datalen); in ossl_blake2s_update() 288 c->buflen += datalen; /* Be lazy, do not compress */ in ossl_blake2s_update() 310 memset(c->buf + c->buflen, 0, sizeof(c->buf) - c->buflen); in ossl_blake2s_final() 311 blake2s_compress(c, c->buf, c->buflen); in ossl_blake2s_final()
|
/freebsd/sys/crypto/siphash/ |
H A D | siphash.c | 64 ctx->buflen = 0; in SipHash_InitX() 99 x = MIN(len, sizeof(ctx->buf.b64) - ctx->buflen); in SipBuf() 100 bcopy(*src, &ctx->buf.b8[ctx->buflen], x); in SipBuf() 101 ctx->buflen += x; in SipBuf() 106 if (ctx->buflen == 8 || final) { in SipBuf() 111 ctx->buflen = 0; in SipBuf() 135 if (ctx->buflen > 0 || len < 8) in SipHash_Update()
|
/freebsd/sys/arm64/include/ |
H A D | bus_dma.h | 14 bus_dma_id_mapped(bus_dma_tag_t dmat, vm_paddr_t buf, bus_size_t buflen) in bus_dma_id_mapped() argument 19 return (tc->impl->id_mapped(dmat, buf, buflen)); in bus_dma_id_mapped() 99 bus_size_t buflen, int flags, bus_dma_segment_t *segs, int *segp) in _bus_dmamap_load_phys() argument 104 return (tc->impl->load_phys(dmat, map, buf, buflen, flags, segs, in _bus_dmamap_load_phys() 122 bus_size_t buflen, struct pmap *pmap, int flags, bus_dma_segment_t *segs, in _bus_dmamap_load_buffer() argument 128 return (tc->impl->load_buffer(dmat, map, buf, buflen, pmap, flags, segs, in _bus_dmamap_load_buffer()
|
/freebsd/sys/riscv/riscv/ |
H A D | busdma_bounce.c | 488 bus_size_t buflen, int flags) in _bus_dmamap_count_phys() argument 499 while (buflen != 0) { in _bus_dmamap_count_phys() 500 sgsize = buflen; in _bus_dmamap_count_phys() 507 buflen -= sgsize; in _bus_dmamap_count_phys() 515 void *buf, bus_size_t buflen, int flags) in _bus_dmamap_count_pages() argument 534 vendaddr = (vm_offset_t)buf + buflen; in _bus_dmamap_count_pages() 583 while (buflen > 0) { in bounce_bus_dmamap_load_phys() 585 sgsize = buflen; in bounce_bus_dmamap_load_phys() 614 buflen -= sgsize; in bounce_bus_dmamap_load_phys() 655 while (buflen > 0) { in bounce_bus_dmamap_load_buffer() [all …]
|
/freebsd/crypto/heimdal/appl/telnet/libtelnet/ |
H A D | auth.c | 597 unsigned char *buf, size_t buflen) in auth_printsub() argument 602 (*ap->printsub)(data, cnt, buf, buflen); in auth_printsub() 604 auth_gen_printsub(data, cnt, buf, buflen); in auth_printsub() 609 unsigned char *buf, size_t buflen) in auth_gen_printsub() argument 616 buf[buflen-1] = '\0'; in auth_gen_printsub() 617 buf[buflen-2] = '*'; in auth_gen_printsub() 618 buflen -= 2; in auth_gen_printsub() 621 for (cp = tbuf; *cp && buflen > 0; --buflen) in auth_gen_printsub() 623 if (buflen <= 0) in auth_gen_printsub()
|
/freebsd/contrib/telnet/libtelnet/ |
H A D | auth.c | 586 auth_printsub(unsigned char *data, int cnt, unsigned char *buf, int buflen) in auth_printsub() argument 591 (*ap->printsub)(data, cnt, buf, buflen); in auth_printsub() 593 auth_gen_printsub(data, cnt, buf, buflen); in auth_printsub() 597 auth_gen_printsub(unsigned char *data, int cnt, unsigned char *buf, int buflen) in auth_gen_printsub() argument 604 buf[buflen-1] = '\0'; in auth_gen_printsub() 605 buf[buflen-2] = '*'; in auth_gen_printsub() 606 buflen -= 2; in auth_gen_printsub() 609 for (cp = tbuf; *cp && buflen > 0; --buflen) in auth_gen_printsub() 611 if (buflen <= 0) in auth_gen_printsub()
|
/freebsd/sys/x86/include/ |
H A D | bus_dma.h | 40 bus_dma_id_mapped(bus_dma_tag_t dmat, vm_paddr_t buf, bus_size_t buflen) in bus_dma_id_mapped() argument 45 return (tc->impl->id_mapped(dmat, buf, buflen)); in bus_dma_id_mapped() 133 bus_size_t buflen, int flags, bus_dma_segment_t *segs, int *segp) in _bus_dmamap_load_phys() argument 138 return (tc->impl->load_phys(dmat, map, buf, buflen, flags, segs, in _bus_dmamap_load_phys() 160 bus_size_t buflen, struct pmap *pmap, int flags, bus_dma_segment_t *segs, in _bus_dmamap_load_buffer() argument 166 return (tc->impl->load_buffer(dmat, map, buf, buflen, pmap, flags, segs, in _bus_dmamap_load_buffer()
|
/freebsd/sbin/ddb/ |
H A D | ddb_capture.c | 124 size_t buflen, len; in ddb_capture_print_sysctl() local 129 if (sysctlbyname(SYSCTL_DDB_CAPTURE_DATA, NULL, &buflen, NULL, 0) < 0) in ddb_capture_print_sysctl() 131 if (buflen == 0) in ddb_capture_print_sysctl() 133 buffer = malloc(buflen); in ddb_capture_print_sysctl() 136 bzero(buffer, buflen); in ddb_capture_print_sysctl() 137 len = buflen; in ddb_capture_print_sysctl()
|
/freebsd/contrib/netbsd-tests/lib/libbpfjit/ |
H A D | t_cop.c | 74 return args->buflen; in retBL() 147 .buflen = sizeof(pkt), in ATF_TC_BODY() 180 .buflen = sizeof(pkt), in ATF_TC_BODY() 213 .buflen = sizeof(pkt), in ATF_TC_BODY() 246 .buflen = sizeof(pkt), in ATF_TC_BODY() 282 .buflen = sizeof(pkt), in ATF_TC_BODY() 324 .buflen = sizeof(pkt), in ATF_TC_BODY() 402 .buflen = sizeof(pkt), in ATF_TC_BODY() 436 .buflen = sizeof(pkt), in ATF_TC_BODY() 470 .buflen = sizeof(pkt), in ATF_TC_BODY() [all …]
|
/freebsd/contrib/unbound/util/ |
H A D | proxy_protocol.c | 86 pp2_write_to_buf(uint8_t* buf, size_t buflen, in pp2_write_to_buf() argument 99 if(buflen < expected_size) { in pp2_write_to_buf() 164 pp2_read_header(uint8_t* buf, size_t buflen) in pp2_read_header() argument 169 if(buflen < PP2_HEADER_SIZE) { in pp2_read_header() 179 if(buflen < size) { in pp2_read_header()
|
/freebsd/crypto/openssl/providers/implementations/ciphers/ |
H A D | ciphercommon_local.h | 12 void ossl_cipher_padblock(unsigned char *buf, size_t *buflen, size_t blocksize); 13 int ossl_cipher_unpadblock(unsigned char *buf, size_t *buflen, size_t blocksize); 15 unsigned char *buf, size_t *buflen, size_t blocksize,
|
/freebsd/usr.sbin/extattr/ |
H A D | rmextattr.c | 116 int buflen = 0; in main() local 249 mkbuf(&buf, &buflen, ret); in main() 252 attrnamespace, buf, buflen); in main() 255 attrnamespace, buf, buflen); in main() 278 mkbuf(&buf, &buflen, ret); in main() 281 attrnamespace, attrname, buf, buflen); in main() 284 attrnamespace, attrname, buf, buflen); in main()
|
/freebsd/contrib/wpa/src/tls/ |
H A D | tlsv1_common.c | 422 size_t buflen; in tls_verify_signature() local 447 buflen = end - pos; in tls_verify_signature() 453 if (crypto_public_key_decrypt_pkcs1(pk, pos, end - pos, buf, &buflen) < in tls_verify_signature() 463 decrypted, buflen); in tls_verify_signature() 481 if (buflen >= 19 + 32 && in tls_verify_signature() 487 buflen -= 19; in tls_verify_signature() 488 } else if (buflen >= 19 + 48 && in tls_verify_signature() 494 buflen -= 19; in tls_verify_signature() 495 } else if (buflen >= 19 + 64 && in tls_verify_signature() 501 buflen -= 19; in tls_verify_signature() [all …]
|
/freebsd/sys/dev/ocs_fc/ |
H A D | ocs_gendump.c | 248 ocs_dump_to_host(ocs_t *ocs, void *buf, uint32_t buflen) in ocs_dump_to_host() argument 255 if (buflen == 0) { in ocs_dump_to_host() 260 num_buffers = ((buflen + OCS_MAX_DMA_ALLOC - 1) / OCS_MAX_DMA_ALLOC); in ocs_dump_to_host() 270 rem_bytes = buflen; in ocs_dump_to_host() 319 ocs_function_speciic_dump(ocs_t *ocs, void *buf, uint32_t buflen) in ocs_function_speciic_dump() argument 326 if (buflen == 0) { in ocs_function_speciic_dump() 331 num_buffers = ((buflen + OCS_MAX_DMA_ALLOC - 1) / OCS_MAX_DMA_ALLOC); in ocs_function_speciic_dump() 341 rem_bytes = buflen; in ocs_function_speciic_dump()
|
/freebsd/contrib/wpa/src/utils/ |
H A D | json.c | 513 size_t buflen; in json_get_member_base64url() local 520 &buflen); in json_get_member_base64url() 523 ret = wpabuf_alloc_ext_data(buf, buflen); in json_get_member_base64url() 536 size_t buflen; in json_get_member_base64() local 545 ret = wpabuf_alloc_ext_data(buf, buflen); in json_get_member_base64() 576 char *buf, size_t buflen) in json_print_token() argument 584 ret = os_snprintf(buf + len, buflen - len, "[%d:%s:%s]", in json_print_token() 587 if (os_snprintf_error(buflen - len, ret)) { in json_print_token() 591 json_print_token(token->child, depth + 1, buf, buflen); in json_print_token() 592 json_print_token(token->sibling, depth, buf, buflen); in json_print_token() [all …]
|
/freebsd/usr.bin/netstat/ |
H A D | sctp.c | 160 while (*offset < buflen) { in sctp_skip_xinpcb_ifneed() 167 while (*offset < buflen) { in sctp_skip_xinpcb_ifneed() 175 while (*offset < buflen) { in sctp_skip_xinpcb_ifneed() 182 while (*offset < buflen) { in sctp_skip_xinpcb_ifneed() 216 while (*offset < buflen) { in sctp_process_tcb() 237 while (*offset < buflen) { in sctp_process_tcb() 321 char *buf, const size_t buflen, size_t *offset) in sctp_process_inpcb() argument 364 sctp_skip_xinpcb_ifneed(buf, buflen, offset); in sctp_process_inpcb() 399 while (*offset < buflen) { in sctp_process_inpcb() 470 while (xstcb->last == 0 && *offset < buflen) { in sctp_process_inpcb() [all …]
|
/freebsd/sys/contrib/openzfs/tests/zfs-tests/cmd/ |
H A D | devname2devid.c | 48 udev_device_get_devid(struct udev_device *dev, char *bufptr, size_t buflen) in udev_device_get_devid() argument 67 (void) snprintf(bufptr, buflen, "dm-uuid-%s", dm_uuid); in udev_device_get_devid() 86 (void) stpncpy(bufptr, name, buflen - 1); in udev_device_get_devid() 87 bufptr[buflen - 1] = '\0'; in udev_device_get_devid()
|