Home
last modified time | relevance | path

Searched refs:len (Results 1 – 25 of 783) sorted by relevance

12345678910>>...32

/tools/testing/selftests/net/
A Dproc_net_pktgen.c116 ssize_t len; in FIXTURE_SETUP() local
136 ssize_t len; in FIXTURE_TEARDOWN() local
162 ssize_t len; in TEST_F() local
220 ssize_t len; in TEST_F() local
266 ssize_t len; in TEST_F() local
273 ssize_t len; in TEST_F() local
280 ssize_t len; in TEST_F() local
334 ssize_t len; in TEST_F() local
346 ssize_t len; in TEST_F() local
353 ssize_t len; in TEST_F() local
[all …]
/tools/testing/selftests/bpf/progs/
A Dtest_varlen.c47 long len; in handler64_unsigned() local
54 if (len >= 0) { in handler64_unsigned()
55 payload += len; in handler64_unsigned()
60 if (len >= 0) { in handler64_unsigned()
61 payload += len; in handler64_unsigned()
77 long len; in handler64_signed() local
84 if (len >= 0) { in handler64_signed()
89 if (len >= 0) { in handler64_signed()
103 u32 len; in handler32_unsigned() local
131 long len; in handler32_signed() local
[all …]
A Dfexit_bpf2bpf.c13 unsigned int len; member
20 int len; in BPF_PROG() local
23 len = skb->len; in BPF_PROG()
35 int len; in BPF_PROG() local
38 len = skb->len; in BPF_PROG()
70 int len; in test_subprog2() local
72 bpf_probe_read_kernel(&len, sizeof(len), in test_subprog2()
92 int len; in BPF_PROG() local
95 len = skb->len; in BPF_PROG()
107 int len = skb->len; in new_get_skb_len() local
[all …]
A Dtest_module_attach.c16 raw_tp_read_sz = BPF_CORE_READ(read_ctx, len); in BPF_PROG()
26 raw_tp_bare_write_sz = BPF_CORE_READ(write_ctx, len); in BPF_PROG()
50 tp_btf_read_sz = read_ctx->len; in BPF_PROG()
59 struct bin_attribute *bin_attr, char *buf, loff_t off, size_t len) in BPF_PROG() argument
61 fentry_read_sz = len; in BPF_PROG()
70 struct bin_attribute *bin_attr, char *buf, loff_t off, size_t len) in BPF_PROG() argument
72 fentry_manual_read_sz = len; in BPF_PROG()
83 fentry_explicit_read_sz = len; in BPF_PROG()
95 fentry_explicit_manual_read_sz = len; in BPF_PROG()
108 fexit_read_sz = len; in BPF_PROG()
[all …]
/tools/include/nolibc/
A Dstring.h44 pos = len; in memmove()
52 while (len) { in memmove()
55 len--; in memmove()
139 for (len = 0; str[len]; len++) in strlen()
161 for (len = 0; (len < maxlen) && str[len]; len++); in strnlen()
208 len++; in strlcat()
216 len++; in strlcat()
226 for (len = 0; len < size; len++) { in strlcpy()
227 dst[len] = src[len]; in strlcpy()
235 len++; in strlcpy()
[all …]
/tools/perf/util/
A Dstrbuf.c41 *sz = sb->len; in strbuf_detach()
54 if (nr <= sb->len) in strbuf_grow()
90 memcpy(sb->buf + sb->len, data, len); in strbuf_add()
91 return strbuf_setlen(sb, sb->len + len); in strbuf_add()
96 int len, ret; in strbuf_addv() local
106 len = vsnprintf(sb->buf + sb->len, sb->alloc - sb->len, fmt, ap); in strbuf_addv()
107 if (len < 0) { in strbuf_addv()
109 return len; in strbuf_addv()
117 len = vsnprintf(sb->buf + sb->len, sb->alloc - sb->len, fmt, ap_saved); in strbuf_addv()
125 return strbuf_setlen(sb, sb->len + len); in strbuf_addv()
[all …]
/tools/perf/util/intel-pt-decoder/
A Dintel-pt-pkt-decoder.c79 if (len < 8) in intel_pt_get_long_tnt()
101 if (len < 8) in intel_pt_get_pip()
120 if (len < 4) in intel_pt_get_cbr()
130 if (len < 7) in intel_pt_get_vmcs()
151 if (len < 16) in intel_pt_get_psb()
172 if (len < 7) in intel_pt_get_tma()
200 if (len < 3) in intel_pt_get_3byte()
259 if (len < 4) in intel_pt_get_pwre()
269 if (len < 7) in intel_pt_get_pwrx()
428 len -= 1; in intel_pt_get_cyc()
[all …]
/tools/testing/selftests/powerpc/ptrace/
A Dptrace-hwbreak.c130 for (len = 1; len <= sizeof(glvar); len <<= 1) in test_workload()
134 for (len = 1; len <= sizeof(glvar); len <<= 1) in test_workload()
138 for (len = 1; len <= sizeof(glvar); len <<= 1) { in test_workload()
281 int len; in test_set_debugreg() local
287 for (len = 1; len <= sizeof(glvar); len <<= 1) { in test_set_debugreg()
297 for (len = 1; len <= sizeof(glvar); len <<= 1) { in test_set_debugreg()
308 for (len = 1; len <= sizeof(glvar); len <<= 1) { in test_set_debugreg()
402 int len; in test_sethwdebug_range_aligned() local
501 int len; in test_sethwdebug_range_unaligned() local
538 int len; in test_sethwdebug_range_unaligned_dar() local
[all …]
/tools/power/acpi/tools/acpidbg/
A Dacpidbg.c126 int len; in acpi_aml_read() local
130 len = read(fd, p, len); in acpi_aml_read()
141 int len; in acpi_aml_read_batch_cmd() local
162 int len; in acpi_aml_read_batch_log() local
170 len = 1; in acpi_aml_read_batch_log()
226 int len; in acpi_aml_write() local
230 len = write(fd, p, len); in acpi_aml_write()
241 int len; in acpi_aml_write_batch_log() local
246 len = write(fd, p, len); in acpi_aml_write_batch_log()
257 int len; in acpi_aml_write_batch_cmd() local
[all …]
/tools/testing/selftests/proc/
A Dproc-uptime-002.c35 static inline int sys_sched_getaffinity(pid_t pid, unsigned int len, unsigned long *m) in sys_sched_getaffinity() argument
37 return syscall(SYS_sched_getaffinity, pid, len, m); in sys_sched_getaffinity()
42 return syscall(SYS_sched_setaffinity, pid, len, m); in sys_sched_setaffinity()
48 unsigned int len; in main() local
55 len = 0; in main()
57 len += sizeof(unsigned long); in main()
59 m = malloc(len); in main()
60 } while (sys_sched_getaffinity(0, len, m) == -1 && errno == EINVAL); in main()
68 for (cpu = 0; cpu < len * 8; cpu++) { in main()
69 memset(m, 0, len); in main()
[all …]
/tools/testing/selftests/bpf/prog_tests/
A Dsocket_helpers.h152 socklen_t *len) in init_addr_loopback4() argument
159 *len = sizeof(*addr4); in init_addr_loopback4()
163 socklen_t *len) in init_addr_loopback6() argument
170 *len = sizeof(*addr6); in init_addr_loopback6()
174 socklen_t *len) in init_addr_loopback_unix() argument
183 socklen_t *len) in init_addr_loopback_vsock() argument
190 *len = sizeof(*addr); in init_addr_loopback_vsock()
194 socklen_t *len) in init_addr_loopback() argument
232 socklen_t len = 0; in socket_loopback_reuseport() local
331 socklen_t len; in create_pair() local
[all …]
A Dtask_fd_query_rawtp.c8 __u32 len, prog_id, fd_type; in test_task_fd_query_rawtp() local
23 len = sizeof(buf); in test_task_fd_query_rawtp()
24 err = bpf_task_fd_query(getpid(), efd, 0, buf, &len, &prog_id, in test_task_fd_query_rawtp()
37 len = 0; in test_task_fd_query_rawtp()
38 err = bpf_task_fd_query(getpid(), efd, 0, buf, &len, &prog_id, in test_task_fd_query_rawtp()
44 len == strlen("sys_enter"); in test_task_fd_query_rawtp()
49 len = sizeof(buf); in test_task_fd_query_rawtp()
50 err = bpf_task_fd_query(getpid(), efd, 0, 0, &len, &prog_id, in test_task_fd_query_rawtp()
56 len == strlen("sys_enter"); in test_task_fd_query_rawtp()
61 len = 3; in test_task_fd_query_rawtp()
[all …]
/tools/testing/selftests/powerpc/copyloops/
A Dvalidate.c30 memcpy(srcp, fill, len); in do_one()
32 ret = COPY_LOOP(dstp, srcp, len); in do_one()
38 if (memcmp(dstp, srcp, len)) { in do_one()
41 for (i = 0; i < len; i++) in do_one()
44 for (i = 0; i < len; i++) in do_one()
52 dstp, srcp, len); in do_one()
56 if (memcmp(dstp+len, redzone, dst+BUFLEN-(dstp+len))) { in do_one()
58 dstp, srcp, len); in do_one()
66 unsigned long len, src_off, dst_off; in test_copy_loop() local
85 for (len = 1; len < MAX_LEN; len++) { in test_copy_loop()
[all …]
/tools/spi/
A Dspidev_fdx.c24 if (len < 2) in do_read()
25 len = 2; in do_read()
26 else if (len > sizeof(buf)) in do_read()
27 len = sizeof(buf); in do_read()
30 status = read(fd, buf, len); in do_read()
35 if (status != len) { in do_read()
58 if (len > sizeof buf) in do_msg()
59 len = sizeof buf; in do_msg()
63 xfer[0].len = 1; in do_msg()
66 xfer[1].len = len; in do_msg()
[all …]
/tools/testing/selftests/net/tcp_ao/lib/
A Drepair.c45 socklen_t len; in test_sock_checkpoint_queue() local
51 len = sizeof(q->seq); in test_sock_checkpoint_queue()
53 if (ret || len != sizeof(q->seq)) in test_sock_checkpoint_queue()
81 len = addr_size; in __test_sock_checkpoint()
82 if (getsockname(sk, addr, &len) || len != addr_size) in __test_sock_checkpoint()
85 len = sizeof(state->trw); in __test_sock_checkpoint()
104 len = sizeof(state->mss); in __test_sock_checkpoint()
138 int chunk = len; in test_sock_restore_queue()
141 if (len == 0) in test_sock_restore_queue()
159 len -= ret; in test_sock_restore_queue()
[all …]
/tools/arch/x86/dell-uart-backlight-emulator/
A Ddell-uart-backlight-emulator.c28 while (len-- > 0) in dell_uart_checksum()
29 val += buf[len]; in dell_uart_checksum()
45 int ret, idx, len = 0; in main() local
86 case 0x6a: len = 3; break; in main()
87 case 0x8a: len = 4; break; in main()
95 if (idx != (len - 1)) { in main()
106 buf[len - 1], csum); in main()
122 len = 0; in main()
127 len = 1; in main()
137 len = 0; in main()
[all …]
/tools/testing/selftests/breakpoints/
A Dbreakpoint_test.c73 switch (len) { in toggle_breakpoint()
153 switch (len) { in write_var()
181 switch (len) { in read_var()
205 int len, local, global, i; in trigger_tests() local
232 for (len = 1; len <= sizeof(long); len <<= 1) { in trigger_tests()
237 write_var(len); in trigger_tests()
243 for (len = 1; len <= sizeof(long); len <<= 1) { in trigger_tests()
248 read_var(len); in trigger_tests()
335 int len, local, global, i; in launch_tests() local
353 for (len = 1; len <= sizeof(long); len <<= 1) { in launch_tests()
[all …]
/tools/testing/selftests/bpf/
A Dnetlink_helpers.c91 int len; in __rtnl_recvmsg() local
96 if (len < 0) { in __rtnl_recvmsg()
105 return len; in __rtnl_recvmsg()
112 int len; in rtnl_recvmsg() local
118 if (len < 0) in rtnl_recvmsg()
119 return len; in rtnl_recvmsg()
121 len = 32768; in rtnl_recvmsg()
132 return len; in rtnl_recvmsg()
138 return len; in rtnl_recvmsg()
204 len); in __rtnl_talk_iov()
[all …]
/tools/testing/selftests/nci/
A Dnci_dev.c24 #define NLA_PAYLOAD(len) ((len) - NLA_HDRLEN) argument
186 int len; in get_family_id() local
200 len = 0; in get_family_id()
282 int len; in get_dev_enable_state() local
286 len = 0; in get_dev_enable_state()
325 int len; in virtual_dev_open() local
365 int len; in virtual_dev_open_v2() local
456 int len; in virtual_deinit() local
478 int len; in virtual_deinit_v2() local
541 int len; in virtual_poll_start() local
[all …]
/tools/include/uapi/linux/
A Dnetlink.h90 #define NLMSG_ALIGN(len) ( ((len)+NLMSG_ALIGNTO-1) & ~(NLMSG_ALIGNTO-1) ) argument
92 #define NLMSG_LENGTH(len) ((len) + NLMSG_HDRLEN) argument
93 #define NLMSG_SPACE(len) NLMSG_ALIGN(NLMSG_LENGTH(len)) argument
95 #define NLMSG_NEXT(nlh,len) ((len) -= NLMSG_ALIGN((nlh)->nlmsg_len), \ argument
97 #define NLMSG_OK(nlh,len) ((len) >= (int)sizeof(struct nlmsghdr) && \ argument
99 (nlh)->nlmsg_len <= (len))
100 #define NLMSG_PAYLOAD(nlh,len) ((nlh)->nlmsg_len - NLMSG_SPACE((len))) argument
231 #define NLA_ALIGN(len) (((len) + NLA_ALIGNTO - 1) & ~(NLA_ALIGNTO - 1)) argument
/tools/testing/selftests/mm/
A Dhugetlb-read-hwpoison.c46 for (size_t offset = 0; offset < len; in setup_filemap()
59 for (i = 0; i < len; ++i) { in verify_chunk()
86 while (offset + total_ret_count < len) { in seek_read_hugepage_filemap()
117 while (total_ret_count < len) { in read_hugepage_filemap()
144 if (ftruncate(fd, len) < 0) { in test_hugetlb_read()
159 if (read_hugepage_filemap(fd, len, wr_chunk_size, len)) in test_hugetlb_read()
162 munmap(filemap, len); in test_hugetlb_read()
181 if (ftruncate(fd, len) < 0) { in test_hugetlb_read_hwpoison()
202 hwp_addr = filemap + len / 2 + pagesize; in test_hugetlb_read_hwpoison()
214 len / 2 + pagesize)) in test_hugetlb_read_hwpoison()
[all …]
/tools/perf/tests/shell/coresight/thread_loop/
A Dthread_loop.c28 int i = 0, len = a->loops; in thrfn() local
41 : /* in */ [i] "r" (i), [len] "r" (len) in thrfn()
59 unsigned int i, len, thr; in main() local
72 len = atoi(argv[2]); in main()
73 if ((len < 1) || (len > 4000)) { in main()
77 len *= 1000000; in main()
79 args[i].loops = len; in main()
/tools/bpf/
A Dbpf_jit_disasm.c39 ssize_t len; in get_exec_path() local
48 if (len < 0) in get_exec_path()
49 len = 0; in get_exec_path()
50 tpath[len] = 0; in get_exec_path()
110 int ret, len; in get_klog_buff() local
114 if (len < 0) in get_klog_buff()
117 buff = malloc(len); in get_klog_buff()
133 int fd, ret, len; in get_flog_buff() local
146 buff = malloc(len); in get_flog_buff()
325 len -= nr; in main()
[all …]
/tools/testing/selftests/sched_ext/
A Dutil.c16 ssize_t len; in read_text() local
23 len = read(fd, buf, max_len - 1); in read_text()
25 if (len >= 0) in read_text()
26 buf[len] = 0; in read_text()
29 return len < 0 ? -errno : len; in read_text()
33 static ssize_t write_text(const char *path, char *buf, ssize_t len) in write_text() argument
42 written = write(fd, buf, len); in write_text()
/tools/perf/ui/tui/
A Dutil.c89 len = sep - t; in ui_browser__input_window()
91 max_len = len; in ui_browser__input_window()
117 len = 5; in ui_browser__input_window()
118 while (len--) { in ui_browser__input_window()
131 len = 0; in ui_browser__input_window()
137 if (len == 0) { in ui_browser__input_window()
144 buf[len] = key; in ui_browser__input_window()
162 buf[len] = '\0'; in ui_browser__input_window()
176 int len; in __ui__info_window() local
180 len = sep - t; in __ui__info_window()
[all …]

Completed in 55 milliseconds

12345678910>>...32