| /tools/include/linux/ |
| D | overflow.h | 84 size_t bytes; in array_size() local 86 if (check_mul_overflow(a, b, &bytes)) in array_size() 89 return bytes; in array_size() 106 size_t bytes; in array3_size() local 108 if (check_mul_overflow(a, b, &bytes)) in array3_size() 110 if (check_mul_overflow(bytes, c, &bytes)) in array3_size() 113 return bytes; in array3_size() 118 size_t bytes; in __ab_c_size() local 120 if (check_mul_overflow(n, size, &bytes)) in __ab_c_size() 122 if (check_add_overflow(bytes, c, &bytes)) in __ab_c_size() [all …]
|
| /tools/testing/selftests/bpf/progs/ |
| D | test_sockmap_kern.h | 236 int *bytes, zero = 0, one = 1, two = 2, three = 3, four = 4, five = 5; in bpf_prog4() local 239 bytes = bpf_map_lookup_elem(&sock_apply_bytes, &zero); in bpf_prog4() 240 if (bytes) in bpf_prog4() 241 bpf_msg_apply_bytes(msg, *bytes); in bpf_prog4() 242 bytes = bpf_map_lookup_elem(&sock_cork_bytes, &zero); in bpf_prog4() 243 if (bytes) in bpf_prog4() 244 bpf_msg_cork_bytes(msg, *bytes); in bpf_prog4() 267 int *bytes, *start, *end, *start_push, *end_push, *start_pop, *pop, *f; in bpf_prog6() local 271 bytes = bpf_map_lookup_elem(&sock_apply_bytes, &zero); in bpf_prog6() 272 if (bytes) in bpf_prog6() [all …]
|
| D | netcnt_prog.c | 37 percpu_cnt->bytes += skb->len; in bpf_nextcnt() 44 __sync_fetch_and_add(&cnt->bytes, in bpf_nextcnt() 45 percpu_cnt->bytes); in bpf_nextcnt() 46 percpu_cnt->bytes = 0; in bpf_nextcnt() 55 if (cnt->bytes + percpu_cnt->bytes - percpu_cnt->prev_bytes < dt) in bpf_nextcnt() 63 percpu_cnt->prev_bytes = cnt->bytes; in bpf_nextcnt()
|
| /tools/arch/x86/include/asm/ |
| D | insn.h | 19 insn_byte_t bytes[4]; member 36 p->bytes[n] = v; in insn_set_byte() 45 insn_byte_t bytes[4]; member 63 p->bytes[n] = v; in insn_set_byte() 178 return X86_REX2_M(insn->rex_prefix.bytes[1]); in insn_rex2_m_bit() 205 return X86_VEX3_M(insn->vex_prefix.bytes[1]); in insn_vex_m_bits() 207 return X86_EVEX_M(insn->vex_prefix.bytes[1]); in insn_vex_m_bits() 213 return X86_VEX_P(insn->vex_prefix.bytes[1]); in insn_vex_p_bits() 215 return X86_VEX_P(insn->vex_prefix.bytes[2]); in insn_vex_p_bits() 222 return X86_VEX_W(insn->vex_prefix.bytes[2]); in insn_vex_w_bit() [all …]
|
| /tools/lib/ |
| D | string.c | 185 static void *check_bytes8(const u8 *start, u8 value, unsigned int bytes) in check_bytes8() argument 187 while (bytes) { in check_bytes8() 191 bytes--; in check_bytes8() 205 void *memchr_inv(const void *start, int c, size_t bytes) in memchr_inv() argument 211 if (bytes <= 16) in memchr_inv() 212 return check_bytes8(start, value, bytes); in memchr_inv() 228 bytes -= prefix; in memchr_inv() 231 words = bytes / 8; in memchr_inv() 240 return check_bytes8(start, value, bytes % 8); in memchr_inv()
|
| /tools/testing/selftests/bpf/prog_tests/ |
| D | netcnt.c | 19 unsigned long bytes; in serial_test_netcnt() local 61 bytes = netcnt.bytes; in serial_test_netcnt() 66 bytes += percpu_netcnt[cpu].bytes; in serial_test_netcnt() 75 ASSERT_GE(bytes, packets * 104, "bytes"); in serial_test_netcnt()
|
| D | l4lb_all.c | 15 __u64 bytes; in test_l4lb() member 27 __u64 bytes = 0, pkts = 0; in test_l4lb() local 80 bytes += stats[i].bytes; in test_l4lb() 83 if (CHECK_FAIL(bytes != MAGIC_BYTES * NUM_ITER * 2 || in test_l4lb() 85 printf("test_l4lb:FAIL:stats %lld %lld\n", bytes, pkts); in test_l4lb()
|
| D | task_fd_query_tp.c | 8 int err, bytes, efd, prog_fd, pmu_fd; in test_task_fd_query_tp_core() local 30 bytes = read(efd, buf, sizeof(buf)); in test_task_fd_query_tp_core() 32 if (CHECK(bytes <= 0 || bytes >= sizeof(buf), "read", in test_task_fd_query_tp_core() 33 "bytes %d errno %d\n", bytes, errno)) in test_task_fd_query_tp_core()
|
| D | xdp_noinline.c | 17 __u64 bytes; in test_xdp_noinline() member 29 __u64 bytes = 0, pkts = 0; in test_xdp_noinline() local 67 bytes += stats[i].bytes; in test_xdp_noinline() 70 ASSERT_EQ(bytes, MAGIC_BYTES * NUM_ITER * 2, "stats bytes"); in test_xdp_noinline()
|
| D | tp_attach_query.c | 7 int i, j, bytes, efd, err, prog_fd[num_progs], pmu_fd[num_progs]; in serial_test_tp_attach_query() local 29 bytes = read(efd, buf, sizeof(buf)); in serial_test_tp_attach_query() 31 if (CHECK(bytes <= 0 || bytes >= sizeof(buf), in serial_test_tp_attach_query() 32 "read", "bytes %d errno %d\n", bytes, errno)) in serial_test_tp_attach_query()
|
| /tools/include/tools/ |
| D | libc_compat.h | 13 size_t bytes; in reallocarray() local 15 if (unlikely(check_mul_overflow(nmemb, size, &bytes))) in reallocarray() 17 return realloc(ptr, bytes); in reallocarray()
|
| /tools/testing/selftests/net/tcp_ao/ |
| D | seq-ext.c | 72 ssize_t bytes; in server_fn() local 92 bytes = test_server_run(sk, quota, TEST_TIMEOUT_SEC); in server_fn() 93 if (bytes != quota) { in server_fn() 94 if (bytes > 0) in server_fn() 95 test_fail("server served: %zd", bytes); in server_fn() 97 test_fail("server returned: %zd", bytes); in server_fn() 128 bytes = test_server_run(sk, quota, TEST_TIMEOUT_SEC); in server_fn() 129 if (bytes != quota) { in server_fn() 130 if (bytes > 0) in server_fn() 131 test_fail("server served: %zd", bytes); in server_fn() [all …]
|
| D | restore.c | 24 ssize_t bytes; in try_server_run() local 44 bytes = test_server_run(sk, quota, TEST_TIMEOUT_SEC); in try_server_run() 45 if (bytes != quota) { in try_server_run() 46 test_fail("%s: server served: %zd", tst_name, bytes); in try_server_run() 55 bytes = test_server_run(sk, quota, timeout); in try_server_run() 57 if (bytes > 0) in try_server_run() 58 test_fail("%s: server served: %zd", tst_name, bytes); in try_server_run() 62 if (bytes != quota) in try_server_run() 63 test_fail("%s: server served: %zd", tst_name, bytes); in try_server_run()
|
| D | rst.c | 88 ssize_t bytes; in test_server_active_rst() local 111 bytes = test_server_run(sk, quota, 0); in test_server_active_rst() 112 if (bytes != quota) in test_server_active_rst() 113 test_error("servered only %zd bytes", bytes); in test_server_active_rst() 115 test_ok("servered %zd bytes", bytes); in test_server_active_rst() 133 ssize_t bytes; in test_server_passive_rst() local 153 bytes = test_server_run(sk, quota, TEST_TIMEOUT_SEC); in test_server_passive_rst() 154 if (bytes != quota) { in test_server_passive_rst() 155 if (bytes > 0) in test_server_passive_rst() 156 test_fail("server served: %zd", bytes); in test_server_passive_rst() [all …]
|
| D | icmps-accept.c | 59 ssize_t bytes; in serve_interfered() local 66 bytes = test_server_run(sk, test_quota, 0); in serve_interfered() 85 if (bytes < 0) in serve_interfered() 86 test_icmps_fail("Server failed with %zd: %s", bytes, strerrordesc_np(-bytes)); in serve_interfered() 194 ssize_t bytes; in icmp_interfere4() local 220 bytes = sendto(sk, &packet, sizeof(packet), 0, in icmp_interfere4() 222 if (bytes != sizeof(packet)) in icmp_interfere4() 223 test_error("send(): %zd", bytes); in icmp_interfere4() 309 ssize_t bytes; in icmp6_interfere() local 334 bytes = sendto(sk, &packet, sizeof(packet), 0, in icmp6_interfere() [all …]
|
| D | icmps-discard.c | 59 ssize_t bytes; in serve_interfered() local 66 bytes = test_server_run(sk, test_quota, 0); in serve_interfered() 85 if (bytes < 0) in serve_interfered() 86 test_icmps_fail("Server failed with %zd: %s", bytes, strerrordesc_np(-bytes)); in serve_interfered() 194 ssize_t bytes; in icmp_interfere4() local 220 bytes = sendto(sk, &packet, sizeof(packet), 0, in icmp_interfere4() 222 if (bytes != sizeof(packet)) in icmp_interfere4() 223 test_error("send(): %zd", bytes); in icmp_interfere4() 309 ssize_t bytes; in icmp6_interfere() local 334 bytes = sendto(sk, &packet, sizeof(packet), 0, in icmp6_interfere() [all …]
|
| D | connect.c | 9 ssize_t bytes; in server_fn() local 26 bytes = test_server_run(sk, 0, 0); in server_fn() 28 test_fail("server served: %zd", bytes); in server_fn()
|
| /tools/crypto/ |
| D | gen_fips140_testvecs.py | 28 message = bytes('This is a 32-byte test message.\0', 'ascii') 29 aes_key = bytes('128-bit AES key\0', 'ascii') 30 aes_xts_key = bytes('This is an AES-128-XTS key.\0\0\0\0\0', 'ascii') 31 aes_iv = bytes('ABCDEFGHIJKLMNOP', 'ascii') 32 assoc = bytes('associated data string', 'ascii') 33 hmac_key = bytes('128-bit HMAC key', 'ascii') 85 nonce=bytes(), initial_value=aes_iv)
|
| /tools/testing/selftests/net/tcp_ao/lib/ |
| D | sock.c | 507 ssize_t bytes, sent; in test_server_run() local 514 bytes = recv(sk, buf, sizeof(buf), 0); in test_server_run() 516 if (bytes < 0) in test_server_run() 517 test_error("recv(): %zd", bytes); in test_server_run() 518 if (bytes == 0) in test_server_run() 525 sent = send(sk, buf, bytes, 0); in test_server_run() 528 if (sent != bytes) in test_server_run() 530 total += bytes; in test_server_run() 547 size_t sent, bytes = min(msg_len, buf_sz - i); in test_client_loop() local 554 sent = send(sk, buf + i, bytes, 0); in test_client_loop() [all …]
|
| /tools/testing/selftests/kselftest/ |
| D | prefix.pl | 16 my $bytes = sysread(STDIN, $char, 1); 17 exit 0 if ($bytes == 0);
|
| /tools/testing/selftests/tpm2/ |
| D | tpm2.py | 251 def __init__(self, session_handle=TPM2_RS_PW, nonce=bytes(), 252 session_attributes=0, hmac=bytes()): 272 def __init__(self, user_auth=bytes(), data=bytes()): 301 auth_policy=bytes(), parameters=bytes(), 302 unique=bytes()): 452 bytes(auth_cmd), 507 bytes(dig), 544 def create_root_key(self, auth_value = bytes()): 580 bytes(auth_cmd), 582 bytes(sensitive), [all …]
|
| /tools/iio/ |
| D | iio_generic_buffer.c | 56 unsigned int bytes = 0; in size_from_channelarray() local 61 if (channels[i].bytes > max) in size_from_channelarray() 62 max = channels[i].bytes; in size_from_channelarray() 63 if (bytes % channels[i].bytes == 0) in size_from_channelarray() 64 channels[i].location = bytes; in size_from_channelarray() 66 channels[i].location = bytes - bytes % channels[i].bytes in size_from_channelarray() 67 + channels[i].bytes; in size_from_channelarray() 69 bytes = channels[i].location + channels[i].bytes; in size_from_channelarray() 77 misalignment = bytes % max; in size_from_channelarray() 79 bytes += max - misalignment; in size_from_channelarray() [all …]
|
| /tools/testing/selftests/bpf/ |
| D | netcnt_common.h | 26 __u64 bytes; member 39 __u64 bytes; member
|
| D | network_helpers.c | 624 uint32_t bytes; member 631 ssize_t nr_sent = 0, bytes = 0; in send_recv_server() local 648 while (bytes < a->bytes && !READ_ONCE(a->stop)) { in send_recv_server() 650 MIN(a->bytes - bytes, sizeof(batch)), 0); in send_recv_server() 657 bytes += nr_sent; in send_recv_server() 660 if (bytes != a->bytes) { in send_recv_server() 661 log_err("send %zd expected %u", bytes, a->bytes); in send_recv_server() 663 err = bytes > a->bytes ? -E2BIG : -EINTR; in send_recv_server() 678 ssize_t nr_recv = 0, bytes = 0; in send_recv_data() local 681 .bytes = total_bytes, in send_recv_data() [all …]
|
| /tools/tracing/latency/ |
| D | latency-collector.c | 723 int bytes; in sleeptable_resize() local 728 bytes = snprintf(msg->buf, sizeof(msg->buf), in sleeptable_resize() 731 bytes = snprintf(msg->buf, sizeof(msg->buf), in sleeptable_resize() 733 if (bytes < 0) in sleeptable_resize() 736 msg->len = bytes; in sleeptable_resize() 1077 ssize_t bytes = 0; in __print_skipmessage() local 1087 bytes += resize_msg->len; in __print_skipmessage() 1103 bytes += r; in __print_skipmessage() 1107 write_or_die(fd_stdout, buffer, bytes); in __print_skipmessage() 1135 ssize_t bytes = 0; in print_tracefile() local [all …]
|