/freebsd/sys/contrib/openzfs/tests/zfs-tests/cmd/ |
H A D | mmap_seek.c | 92 off_t block_size = atoi(argv[3]); in main() local 94 if (block_size * 2 > file_size) { in main() 125 seek_data(fd, block_size, -1); in main() 126 seek_hole(fd, 0, block_size); in main() 127 seek_hole(fd, block_size, block_size); in main() 132 seek_data(fd, block_size, block_size); in main() 133 seek_hole(fd, 0, P2ROUNDUP(file_size / 2, block_size)); in main() 134 seek_hole(fd, block_size, P2ROUNDUP(file_size / 2, block_size)); in main() 140 P2ROUNDUP(file_size * 3 / 4, block_size)); in main() 145 memset(buf + block_size, 0, block_size); in main() [all …]
|
/freebsd/sys/contrib/openzfs/module/icp/algs/modes/ |
H A D | gcm.c | 85 crypto_data_t *out, size_t block_size, in gcm_mode_encrypt_contiguous_blocks() argument 93 ctx, data, length, out, block_size)); in gcm_mode_encrypt_contiguous_blocks() 110 if (length + ctx->gcm_remainder_len < block_size) { in gcm_mode_encrypt_contiguous_blocks() 128 need = block_size - ctx->gcm_remainder_len; in gcm_mode_encrypt_contiguous_blocks() 156 ctx->gcm_processed_data_len += block_size; in gcm_mode_encrypt_contiguous_blocks() 159 &out_data_1_len, &out_data_2, block_size); in gcm_mode_encrypt_contiguous_blocks() 162 if (out_data_1_len == block_size) { in gcm_mode_encrypt_contiguous_blocks() 169 block_size - out_data_1_len); in gcm_mode_encrypt_contiguous_blocks() 173 out->cd_offset += block_size; in gcm_mode_encrypt_contiguous_blocks() 183 datap += block_size; in gcm_mode_encrypt_contiguous_blocks() [all …]
|
H A D | ccm.c | 42 crypto_data_t *out, size_t block_size, in ccm_mode_encrypt_contiguous_blocks() argument 60 if (length + ctx->ccm_remainder_len < block_size) { in ccm_mode_encrypt_contiguous_blocks() 77 need = block_size - ctx->ccm_remainder_len; in ccm_mode_encrypt_contiguous_blocks() 125 ctx->ccm_processed_data_len += block_size; in ccm_mode_encrypt_contiguous_blocks() 128 &out_data_1_len, &out_data_2, block_size); in ccm_mode_encrypt_contiguous_blocks() 131 if (out_data_1_len == block_size) { in ccm_mode_encrypt_contiguous_blocks() 138 block_size - out_data_1_len); in ccm_mode_encrypt_contiguous_blocks() 142 out->cd_offset += block_size; in ccm_mode_encrypt_contiguous_blocks() 149 datap += block_size; in ccm_mode_encrypt_contiguous_blocks() 155 if (remainder > 0 && remainder < block_size) { in ccm_mode_encrypt_contiguous_blocks() [all …]
|
/freebsd/crypto/libecc/include/libecc/hash/ |
H A D | hash_algs.h | 236 u8 block_size; member 263 .block_size = SHA224_BLOCK_SIZE, 277 .block_size = SHA256_BLOCK_SIZE, 291 .block_size = SHA384_BLOCK_SIZE, 305 .block_size = SHA512_BLOCK_SIZE, 319 .block_size = SHA512_224_BLOCK_SIZE, 333 .block_size = SHA512_256_BLOCK_SIZE, 347 .block_size = SHA3_224_BLOCK_SIZE, 361 .block_size = SHA3_256_BLOCK_SIZE, 375 .block_size = SHA3_384_BLOCK_SIZE, [all …]
|
/freebsd/sys/contrib/openzfs/tests/zfs-tests/cmd/file/ |
H A D | file_write.c | 49 static void randomize_buffer(int block_size) { in randomize_buffer() argument 52 for (i = 0; i < block_size; i++) in randomize_buffer() 73 int block_size = BLOCKSZ; in main() local 87 block_size = atoi(optarg); in main() 136 if (block_size > BIGBUFFERSIZE) { in main() 137 (void) printf("block_size is too large max==%d.\n", in main() 156 for (i = 0; i < block_size; i++) { in main() 210 (void) printf("%s: block_size = %d, write_count = %d, " in main() 211 "offset = %lld, ", filename, block_size, in main() 225 randomize_buffer(block_size); in main() [all …]
|
/freebsd/crypto/libecc/src/examples/hash/ |
H A D | hash.c | 14 …lg_type gen_hash_type, hash_alg_type *hash_type, const hash_mapping **hm, u8 *hlen, u8 *block_size) in get_libecc_hash() argument 151 ret = get_hash_sizes(htype, hlen, block_size); EG(ret, err); in get_libecc_hash() 169 int gen_hash_get_hash_sizes(gen_hash_alg_type gen_hash_type, u8 *hlen, u8 *block_size) in gen_hash_get_hash_sizes() argument 173 MUST_HAVE((hlen != NULL) && (block_size != NULL), ret, err); in gen_hash_get_hash_sizes() 178 (*block_size) = MD2_BLOCK_SIZE; in gen_hash_get_hash_sizes() 184 (*block_size) = MD4_BLOCK_SIZE; in gen_hash_get_hash_sizes() 190 (*block_size) = MD5_BLOCK_SIZE; in gen_hash_get_hash_sizes() 196 (*block_size) = SHA0_BLOCK_SIZE; in gen_hash_get_hash_sizes() 202 (*block_size) = SHA1_BLOCK_SIZE; in gen_hash_get_hash_sizes() 209 (*block_size) = MDC2_BLOCK_SIZE; in gen_hash_get_hash_sizes() [all …]
|
/freebsd/tests/sys/cddl/zfs/bin/ |
H A D | file_write.c | 58 int block_size = BLOCKSZ; in main() local 74 block_size = atoi(optarg); in main() 120 if (block_size > BIGBUFFERSIZE) { in main() 121 (void) printf("block_size is too large max==%d.\n", in main() 134 for (i = 0; i < block_size; i++) { in main() 189 (void) printf("%s: block_size = %d, write_count = %d, " in main() 190 "offset = %"PRId64", data = %s%d\n", filename, block_size, in main() 199 if ((n = write(bigfd, &bigbuffer, block_size)) == -1) { in main() 211 good_writes, (good_writes * block_size)); in main() 229 " [-b block_size]\n" in usage()
|
/freebsd/crypto/openssl/ssl/record/ |
H A D | tls_pad.c | 29 size_t block_size, 39 size_t block_size, size_t mac_size, 47 size_t block_size, size_t mac_size, 60 * block_size: the block size of the cipher used to encrypt the record. 73 size_t block_size, size_t mac_size, in ssl3_cbc_remove_padding_and_mac() argument 89 good &= constant_time_ge_s(block_size, padding_length + 1); in ssl3_cbc_remove_padding_and_mac() 93 block_size, mac_size, good, libctx); in ssl3_cbc_remove_padding_and_mac() 105 * block_size: the block size of the cipher used to encrypt the record. 118 size_t block_size, size_t mac_size, in tls1_cbc_remove_padding_and_mac() argument 124 size_t overhead = ((block_size == 1) ? 0 : 1) /* padding length byte */ in tls1_cbc_remove_padding_and_mac() [all …]
|
/freebsd/contrib/libarchive/libarchive/ |
H A D | archive_write_add_filter_lz4.c | 73 size_t block_size; 230 data->block_size = bkmap[0]; in archive_filter_lz4_open() 232 data->block_size = bkmap[data->block_maximum_size - 4]; in archive_filter_lz4_open() 234 required_size = 4 + 15 + 4 + data->block_size + 4 + 4; in archive_filter_lz4_open() 257 if (data->in_buffer_size < data->block_size + pre_block_size) { in archive_filter_lz4_open() 259 data->in_buffer_size = data->block_size; in archive_filter_lz4_open() 266 data->in_buffer_size = data->block_size; in archive_filter_lz4_open() 439 data->in_buffer == data->in && length >= data->block_size) { in lz4_write_one_block() 440 r = drive_compressor(f, p, data->block_size); in lz4_write_one_block() 442 r = (ssize_t)data->block_size; in lz4_write_one_block() 75 size_t block_size; global() member [all...] |
H A D | archive_read_open_filename.c | 74 size_t block_size; member 96 size_t block_size) in archive_read_open_file() argument 98 return (archive_read_open_filename(a, filename, block_size)); in archive_read_open_file() 103 size_t block_size) in archive_read_open_filename() argument 108 return archive_read_open_filenames(a, filenames, block_size); in archive_read_open_filename() 113 size_t block_size) in archive_read_open_filenames() argument 130 mine->block_size = block_size; in archive_read_open_filenames() 166 size_t block_size) in archive_read_open_filenames_w() argument 182 mine->block_size = block_size; in archive_read_open_filenames_w() 239 size_t block_size) in archive_read_open_filename_w() argument [all …]
|
H A D | archive_read_open_fd.c | 54 size_t block_size; member 65 archive_read_open_fd(struct archive *a, int fd, size_t block_size) in archive_read_open_fd() argument 78 b = malloc(block_size); in archive_read_open_fd() 85 mine->block_size = block_size; in archive_read_open_fd() 119 bytes_read = read(mine->fd, mine->buffer, mine->block_size); in file_read() 149 /* Reduce request to the next smallest multiple of block_size */ in file_skip() 150 request = (request / mine->block_size) * mine->block_size; in file_skip()
|
H A D | archive_read_open_file.c | 54 size_t block_size; member 68 size_t block_size = 128 * 1024; in archive_read_open_FILE() local 73 b = malloc(block_size); in archive_read_open_FILE() 80 mine->block_size = block_size; in archive_read_open_FILE() 114 bytes_read = fread(mine->buffer, 1, mine->block_size, mine->f); in file_read() 115 if (bytes_read < mine->block_size && ferror(mine->f)) { in file_read()
|
/freebsd/sys/dev/usb/ |
H A D | usb_mbuf.c | 65 usb_size_t block_size, uint16_t nblocks) in usb_alloc_mbufs() argument 73 block_size += ((-block_size) & (USB_HOST_ALIGN - 1)); in usb_alloc_mbufs() 75 if (nblocks && block_size) { in usb_alloc_mbufs() 76 alloc_size = (block_size + sizeof(struct usb_mbuf)) * nblocks; in usb_alloc_mbufs() 87 m_ptr->max_data_len = block_size; in usb_alloc_mbufs() 92 data_ptr += block_size; in usb_alloc_mbufs()
|
/freebsd/tools/tools/usbtest/ |
H A D | usb_msc_test.c | 97 static uint32_t block_size = 512; variable 294 len /= block_size; in do_read_10() 304 retval = do_msc_cmd(cmd, 10, buf, len * block_size, 1, 0, lun, 0); in do_read_10() 324 len /= block_size; in do_write_10() 334 retval = do_msc_cmd(cmd, 10, buf, (len * block_size), 0, 0, lun, abort); in do_write_10() 447 retval = do_read_10(io_offset, io_size * block_size, in do_io_test() 448 buffer + (io_offset * block_size), lun); in do_io_test() 451 if (bcmp(buffer + (io_offset * block_size), in do_io_test() 452 reference + (io_offset * block_size), in do_io_test() 453 io_size * block_size)) { in do_io_test() [all …]
|
/freebsd/stand/libofw/ |
H A D | ofw_disk.c | 165 int block_size; in ofwd_ioctl() local 170 block_size = OF_block_size(dev->d_handle); in ofwd_ioctl() 171 *(u_int *)data = block_size; in ofwd_ioctl() 174 block_size = OF_block_size(dev->d_handle); in ofwd_ioctl() 176 *(uint64_t *)data = ((uint64_t)n * block_size); in ofwd_ioctl() 187 uintmax_t block_size, n; in ofwd_print() local 199 block_size = OF_block_size(kdp->d_handle); in ofwd_print() 203 kdp->d_path, n, block_size, n * block_size); in ofwd_print()
|
/freebsd/crypto/openssl/doc/man3/ |
H A D | SSL_CTX_set_record_padding_callback.pod | 27 int SSL_CTX_set_block_padding(SSL_CTX *ctx, size_t block_size); 28 int SSL_set_block_padding(SSL *ssl, size_t block_size); 46 of the B<block_size>. A B<block_size> of 0 or 1 disables block padding. The limit of 47 B<block_size> is SSL3_RT_MAX_PLAIN_LENGTH. 62 or 0 if B<block_size> is too large.
|
/freebsd/contrib/wpa/src/eap_common/ |
H A D | eap_eke_common.c | 587 size_t block_size, icv_len, pad; in eap_eke_prot() local 591 block_size = AES_BLOCK_SIZE; in eap_eke_prot() 602 pad = data_len % block_size; in eap_eke_prot() 604 pad = block_size - pad; in eap_eke_prot() 606 if (*prot_len < block_size + data_len + pad + icv_len) { in eap_eke_prot() 612 if (random_get_bytes(pos, block_size)) in eap_eke_prot() 615 wpa_hexdump(MSG_DEBUG, "EAP-EKE: IV for Prot()", iv, block_size); in eap_eke_prot() 616 pos += block_size; in eap_eke_prot() 641 size_t block_size, icv_len; in eap_eke_decrypt_prot() local 645 block_size = AES_BLOCK_SIZE; in eap_eke_decrypt_prot() [all …]
|
/freebsd/sys/contrib/openzfs/tests/zfs-tests/tests/functional/cli_root/zfs_send/ |
H A D | zfs_send_006_pos.ksh | 96 typeset -l block_size 105 for block_size in 64 128 256; do 106 log_must dd if=/dev/urandom of=/$TESTPOOL/$TESTFS1/file$block_size \ 107 bs=1M count=$block_size 108 log_must zfs snapshot $TESTPOOL/$TESTFS1@snap$block_size 109 log_must zfs bookmark $TESTPOOL/$TESTFS1@snap$block_size \ 110 "$TESTPOOL/$TESTFS1#bmark$block_size"
|
/freebsd/tests/sys/cddl/zfs/tests/reservation/ |
H A D | reservation_016_pos.ksh | 73 vol_set_size=$(floor_volsize $vol_set_size $BLOCK_SIZE) 77 log_must $ZFS create -b $BLOCK_SIZE -V $vol_set_size $TESTPOOL/$TESTVOL 90 write_count=`expr $fill_size / $BLOCK_SIZE` 94 $FILE_WRITE -o create -f $TESTDIR/$TESTFILE1 -b $BLOCK_SIZE \ 103 log_must $FILE_WRITE -o create -f $TESTDIR/$TESTFILE2 -b $BLOCK_SIZE \
|
H A D | reservation_015_pos.ksh | 78 resv_size_set=$(floor_volsize $resv_size_set $BLOCK_SIZE) 80 log_must $ZFS create -b $BLOCK_SIZE -V $resv_size_set $TESTPOOL/$TESTVOL 91 write_count=`expr $fill_size / $BLOCK_SIZE` 95 $FILE_WRITE -o create -f $TESTDIR/$TESTFILE1 -b $BLOCK_SIZE \ 105 log_must $FILE_WRITE -o create -f $TESTDIR/$TESTFILE2 -b $BLOCK_SIZE \
|
H A D | reservation_012_pos.ksh | 82 (( write_count = ( RESV_FREE_SPACE + RESV_TOLERANCE ) / BLOCK_SIZE )) 84 $FILE_WRITE -o create -f $TESTDIR2/$TESTFILE1 -b $BLOCK_SIZE -c $write_count -d 0 90 (( write_count = ( RESV_FREE_SPACE - RESV_TOLERANCE ) / BLOCK_SIZE )) 91 log_must $FILE_WRITE -o create -f $TESTDIR/$TESTFILE2 -b $BLOCK_SIZE -c $write_count -d 0
|
/freebsd/crypto/libecc/scripts/ |
H A D | sha3.py | 92 self.block_size = (25*8) - (2 * (digest_size / 8)) 97 def block_size(self): member in Sha3_ctx 98 return self.block_size 105 if (self.idx == self.block_size): 110 self.state[int(self.block_size - 1)] = chr(ord(self.state[int(self.block_size - 1)]) ^ 0x80)
|
/freebsd/contrib/bearssl/src/mac/ |
H A D | hmac.c | 28 block_size(const br_hash_class *dig) in block_size() function 44 blen = block_size(*hc); in process_key() 65 if (key_len > block_size(dig)) { in br_hmac_key_init() 85 blen = block_size(dig); in br_hmac_init() 114 blen = block_size(dig); in br_hmac_out()
|
/freebsd/sys/contrib/openzfs/tests/zfs-tests/tests/functional/reservation/ |
H A D | reservation_012_pos.ksh | 75 ((write_count = (RESV_FREE_SPACE + RESV_TOLERANCE) / BLOCK_SIZE)) 77 file_write -o create -f $TESTDIR2/$TESTFILE1 -b $BLOCK_SIZE -c $write_count \ 84 ((write_count = (RESV_FREE_SPACE - RESV_TOLERANCE) / BLOCK_SIZE)) 85 log_must file_write -o create -f $TESTDIR/$TESTFILE2 -b $BLOCK_SIZE -c \
|
/freebsd/crypto/openssl/include/crypto/ |
H A D | evp.h | 261 int block_size; member 293 int block_size; member 355 bl = EVP_CIPHER_CTX_get0_cipher(ctx)->block_size; \ 434 #define BLOCK_CIPHER_def1(cname, nmode, mode, MODE, kstruct, nid, block_size, \ argument 438 nid##_##nmode, block_size, key_len, iv_len, \ 451 #define BLOCK_CIPHER_def_cbc(cname, kstruct, nid, block_size, key_len, \ argument 454 BLOCK_CIPHER_def1(cname, cbc, cbc, CBC, kstruct, nid, block_size, key_len, \ 471 #define BLOCK_CIPHER_def_ecb(cname, kstruct, nid, block_size, key_len, \ argument 474 BLOCK_CIPHER_def1(cname, ecb, ecb, ECB, kstruct, nid, block_size, key_len, \ 478 nid, block_size, key_len, iv_len, cbits, flags, \ argument [all …]
|