| /tools/testing/selftests/filesystems/statmount/ |
| A D | listmount_test.c | 36 for (size_t cur = 0; cur < nr_mounts; cur++) { in TEST() local 37 if (cur < nr_mounts - 1) in TEST() 38 ASSERT_LT(list[cur], list[cur + 1]); in TEST() 39 last_mnt_id = list[cur]; in TEST() 58 for (size_t cur = 0; cur < nr_mounts; cur++) { in TEST() local 59 if (cur < nr_mounts - 1) in TEST() 60 ASSERT_GT(list[cur], list[cur + 1]); in TEST() 61 last_mnt_id = list[cur]; in TEST()
|
| /tools/power/cpupower/ |
| A D | cpupower-completion.sh | 11 local cur="${COMP_WORDS[COMP_CWORD]}" 21 local cur="${COMP_WORDS[COMP_CWORD]}" 39 local cur="${COMP_WORDS[COMP_CWORD]}" 41 idle-info) COMPREPLY=($(compgen -W "$flags" -- "$cur")) ;; 49 local cur="${COMP_WORDS[COMP_CWORD]}" 51 idle-set) COMPREPLY=($(compgen -W "$flags" -- "$cur")) ;; 59 local cur="${COMP_WORDS[COMP_CWORD]}" 61 set) COMPREPLY=($(compgen -W "$flags" -- "$cur")) ;; 69 local cur="${COMP_WORDS[COMP_CWORD]}" 71 monitor) COMPREPLY=($(compgen -W "$flags" -- "$cur")) ;; [all …]
|
| /tools/perf/util/ |
| A D | hashmap.h | 170 for (cur = (map)->buckets[bkt]; cur; cur = cur->next) 182 for (cur = (map)->buckets[bkt]; \ 183 cur && ({tmp = cur->next; true; }); \ 184 cur = tmp) 193 for (cur = (map)->buckets \ 196 cur; \ 197 cur = cur->next) \ 198 if ((map)->equal_fn(cur->key, (_key), (map)->ctx)) 201 for (cur = (map)->buckets \ 204 cur && ({ tmp = cur->next; true; }); \ [all …]
|
| A D | strfilter.c | 100 if (!cur) in strfilter_node__new() 103 last_op = cur; in strfilter_node__new() 109 if (!cur) in strfilter_node__new() 111 root.r = cur; in strfilter_node__new() 115 if (cur->r) in strfilter_node__new() 118 if (!cur->r) in strfilter_node__new() 120 cur = cur->r; in strfilter_node__new() 123 if (cur->r) in strfilter_node__new() 133 if (cur->r) in strfilter_node__new() 136 if (!cur->r) in strfilter_node__new() [all …]
|
| A D | hashmap.c | 65 struct hashmap_entry *cur, *tmp; in hashmap__clear() local 68 hashmap__for_each_entry_safe(map, cur, tmp, bkt) { in hashmap__clear() 69 free(cur); in hashmap__clear() 104 struct hashmap_entry *cur, *tmp; in hashmap_grow() local 117 hashmap__for_each_entry_safe(map, cur, tmp, bkt) { in hashmap_grow() 119 hashmap_add_entry(&new_buckets[h], cur); in hashmap_grow() 135 struct hashmap_entry *cur, **prev_ptr; in hashmap_find_entry() local 141 cur; in hashmap_find_entry() 142 prev_ptr = &cur->next, cur = cur->next) { in hashmap_find_entry() 143 if (map->equal_fn(cur->key, key, map->ctx)) { in hashmap_find_entry() [all …]
|
| A D | expr.c | 78 struct hashmap_entry *cur; in ids__free() local 85 zfree(&cur->pkey); in ids__free() 86 zfree(&cur->pvalue); in ids__free() 109 struct hashmap_entry *cur; in ids__union() local 127 ret = hashmap__set(ids1, cur->key, cur->value, &old_key, &old_data); in ids__union() 230 struct hashmap_entry *cur; in expr__subset_of_ids() local 309 struct hashmap_entry *cur; in expr__ctx_clear() local 313 zfree(&cur->pkey); in expr__ctx_clear() 314 zfree(&cur->pvalue); in expr__ctx_clear() 329 zfree(&cur->pkey); in expr__ctx_free() [all …]
|
| A D | hwmon_pmu.c | 239 struct hashmap_entry *cur, *tmp; in hwmon_pmu__read_events() local 325 .type_and_num = cur->key, in hwmon_pmu__read_events() 327 struct hwmon_pmu_event_value *value = cur->pvalue; in hwmon_pmu__read_events() 396 struct hashmap_entry *cur, *tmp; in hwmon_pmu__exit() local 462 struct hashmap_entry *cur; in hwmon_pmu__for_each_event() local 499 .type_and_num = cur->key, in hwmon_pmu__for_each_event() 536 pmu->name, cur->key); in hwmon_pmu__for_each_event() 559 struct hashmap_entry *cur; in hwmon_pmu__have_event() local 578 key.type_and_num = cur->key; in hwmon_pmu__have_event() 601 struct hashmap_entry *cur; in hwmon_pmu__config_term() local [all …]
|
| A D | threads.c | 139 struct hashmap_entry *cur, *tmp; in threads__remove_all_threads() local 144 hashmap__for_each_entry_safe(&table->shard, cur, tmp, bkt) { in threads__remove_all_threads() 147 hashmap__delete(&table->shard, cur->key, /*old_key=*/NULL, &old_value); in threads__remove_all_threads() 174 struct hashmap_entry *cur; in threads__for_each_thread() local 178 hashmap__for_each_entry(&table->shard, cur, bkt) { in threads__for_each_thread() 179 int rc = fn((struct thread *)cur->pvalue, data); in threads__for_each_thread()
|
| /tools/lib/bpf/ |
| A D | hashmap.h | 170 for (cur = (map)->buckets[bkt]; cur; cur = cur->next) 182 for (cur = (map)->buckets[bkt]; \ 183 cur && ({tmp = cur->next; true; }); \ 184 cur = tmp) 193 for (cur = (map)->buckets \ 196 cur; \ 197 cur = cur->next) \ 198 if ((map)->equal_fn(cur->key, (_key), (map)->ctx)) 201 for (cur = (map)->buckets \ 204 cur && ({ tmp = cur->next; true; }); \ [all …]
|
| A D | hashmap.c | 65 struct hashmap_entry *cur, *tmp; in hashmap__clear() local 68 hashmap__for_each_entry_safe(map, cur, tmp, bkt) { in hashmap__clear() 69 free(cur); in hashmap__clear() 104 struct hashmap_entry *cur, *tmp; in hashmap_grow() local 117 hashmap__for_each_entry_safe(map, cur, tmp, bkt) { in hashmap_grow() 119 hashmap_add_entry(&new_buckets[h], cur); in hashmap_grow() 135 struct hashmap_entry *cur, **prev_ptr; in hashmap_find_entry() local 141 cur; in hashmap_find_entry() 142 prev_ptr = &cur->next, cur = cur->next) { in hashmap_find_entry() 143 if (map->equal_fn(cur->key, key, map->ctx)) { in hashmap_find_entry() [all …]
|
| /tools/perf/ |
| A D | perf-completion.sh | 71 cur) 72 cur=$cur_ 158 if [[ $cur == --* ]]; then 163 __perfcomp "$cmds" "$cur" 210 __perfcomp "$evts" "$cur" 224 if [[ $cur == --* ]]; then 229 __perfcomp "$opts" "$cur" 260 local cur_="${2-$cur}" 282 local _ret=1 cur cword prev 283 cur=${words[CURRENT]} [all …]
|
| /tools/bpf/bpftool/bash-completion/ |
| A D | bpftool | 133 "$cur" ) ) 258 local cur prev words cword comp_args 307 cur=${words[cword]} 314 case $cur in 366 "$cur" ) ) 371 "$cur" ) ) 524 "$cur" ) ) 529 "$cur" ) ) 627 -- "$cur" ) ) 659 -- "$cur" ) ) [all …]
|
| /tools/testing/selftests/net/ |
| A D | tap.c | 319 cur += build_eth(cur, ETH_P_IP); in build_test_packet_valid_udp_gso() 320 cur += build_ipv4_header(cur, payload_len); in build_test_packet_valid_udp_gso() 321 cur += build_udp_packet(cur, payload_len, true); in build_test_packet_valid_udp_gso() 323 return cur - buf; in build_test_packet_valid_udp_gso() 335 cur += build_eth(cur, ETH_P_IP); in build_test_packet_valid_udp_csum() 336 cur += build_ipv4_header(cur, payload_len); in build_test_packet_valid_udp_csum() 337 cur += build_udp_packet(cur, payload_len, false); in build_test_packet_valid_udp_csum() 339 return cur - buf; in build_test_packet_valid_udp_csum() 354 cur += build_eth(cur, 0); in build_test_packet_crash_tap_invalid_eth_proto() 356 cur += build_ipv4_header(cur, payload_len); in build_test_packet_crash_tap_invalid_eth_proto() [all …]
|
| A D | udpgso_bench_rx.c | 194 char cur = data[0]; in do_verify_udp() local 198 if (cur < 'a' || cur > 'z') in do_verify_udp() 202 if (cur == 'z') in do_verify_udp() 203 cur = 'a'; in do_verify_udp() 205 cur++; in do_verify_udp() 207 if (data[i] != cur) in do_verify_udp() 211 sanitized_char(cur), cur); in do_verify_udp()
|
| A D | txtimestamp.c | 162 cur64 = timespec_to_us64(cur); in validate_timestamp() 187 if (!(cur->tv_sec | cur->tv_nsec)) in __print_timestamp() 192 name, cur->tv_sec, cur->tv_nsec, in __print_timestamp() 196 name, cur->tv_sec, cur->tv_nsec / NSEC_PER_USEC, in __print_timestamp() 199 if (cur != &ts_usr) { in __print_timestamp() 838 struct addrinfo *addrs, *cur; in resolve_hostname() local 845 cur = addrs; in resolve_hostname() 846 while (cur && !have_ipv4 && !have_ipv6) { in resolve_hostname() 847 if (!have_ipv4 && cur->ai_family == AF_INET) { in resolve_hostname() 848 memcpy(&daddr, cur->ai_addr, sizeof(daddr)); in resolve_hostname() [all …]
|
| /tools/testing/selftests/mm/ |
| A D | mlock-random-test.c | 137 struct rlimit cur; in test_mlock_within_limit() local 140 getrlimit(RLIMIT_MEMLOCK, &cur); in test_mlock_within_limit() 141 if (cur.rlim_cur < alloc_size) in test_mlock_within_limit() 143 alloc_size, (unsigned int)cur.rlim_cur); in test_mlock_within_limit() 204 struct rlimit cur; in test_mlock_outof_limit() local 206 getrlimit(RLIMIT_MEMLOCK, &cur); in test_mlock_outof_limit() 207 if (cur.rlim_cur >= alloc_size) in test_mlock_outof_limit() 209 alloc_size, (unsigned int)cur.rlim_cur); in test_mlock_outof_limit() 215 int lock_size = (rand() % (alloc_size - cur.rlim_cur)) in test_mlock_outof_limit() 216 + cur.rlim_cur; in test_mlock_outof_limit()
|
| /tools/lib/ |
| A D | bitmap.c | 35 unsigned int cur, rbot, rtop; in bitmap_scnprintf() local 39 rbot = cur = find_first_bit(bitmap, nbits); in bitmap_scnprintf() 40 while (cur < nbits) { in bitmap_scnprintf() 41 rtop = cur; in bitmap_scnprintf() 42 cur = find_next_bit(bitmap, nbits, cur + 1); in bitmap_scnprintf() 43 if (cur < nbits && cur <= rtop + 1) in bitmap_scnprintf() 55 rbot = cur; in bitmap_scnprintf()
|
| /tools/testing/radix-tree/ |
| A D | main.c | 167 cur = start; in copy_tag_check() 169 end = cur; in copy_tag_check() 173 cur = rand(); in copy_tag_check() 174 if (cur & 1) { in copy_tag_check() 176 if (cur & 2) { in copy_tag_check() 182 if (cur & 4) { in copy_tag_check() 184 if (cur & 8) in copy_tag_check() 187 if (cur & 16) { in copy_tag_check() 189 if (cur & 32) { in copy_tag_check() 195 if (cur & 64) { in copy_tag_check() [all …]
|
| /tools/bpf/bpftool/ |
| A D | cfg.c | 136 func = cfg_append_func(cfg, cur); in cfg_partition_funcs() 140 for (; cur < end; cur++) { in cfg_partition_funcs() 143 if (cur->src_reg != BPF_PSEUDO_CALL) in cfg_partition_funcs() 145 func = cfg_append_func(cfg, cur + cur->off + 1); in cfg_partition_funcs() 167 struct bpf_insn *cur, *end; in func_partition_bb_head() local 170 cur = func->start; in func_partition_bb_head() 173 bb = func_append_bb(func, cur); in func_partition_bb_head() 177 for (; cur <= end; cur++) { in func_partition_bb_head() 178 if (is_jmp_insn(cur->code)) { in func_partition_bb_head() 179 __u8 opcode = BPF_OP(cur->code); in func_partition_bb_head() [all …]
|
| A D | xlated_dumper.c | 382 struct bpf_insn *cur = insn_start; in dump_xlated_for_graph() local 387 for (; cur <= insn_end; cur++) { in dump_xlated_for_graph() 394 double_insn = cur->code == (BPF_LD | BPF_IMM | BPF_DW); in dump_xlated_for_graph() 396 insn_off = (unsigned int)(cur - insn_start + start_idx); in dump_xlated_for_graph() 419 print_bpf_insn(&cbs, cur, true); in dump_xlated_for_graph() 423 fprint_hex(stdout, cur, 8, " "); in dump_xlated_for_graph() 424 if (double_insn && cur <= insn_end - 1) { in dump_xlated_for_graph() 426 fprint_hex(stdout, cur + 1, 8, " "); in dump_xlated_for_graph() 431 if (cur != insn_end) in dump_xlated_for_graph()
|
| /tools/power/cpupower/utils/helpers/ |
| A D | bitmask.c | 279 unsigned int cur, rbot, rtop; in bitmask_displaylist() local 283 rbot = cur = bitmask_first(bmp); in bitmask_displaylist() 284 while (cur < bmp->size) { in bitmask_displaylist() 285 rtop = cur; in bitmask_displaylist() 286 cur = bitmask_next(bmp, cur+1); in bitmask_displaylist() 287 if (cur >= bmp->size || cur > rtop + 1) { in bitmask_displaylist() 289 rbot = cur; in bitmask_displaylist()
|
| /tools/testing/selftests/x86/ |
| A D | test_shadow_stack.c | 578 cur = malloc(sizeof(*cur)); in test_guard_gap_other_gaps() 581 cur->next = head; in test_guard_gap_other_gaps() 582 head = cur; in test_guard_gap_other_gaps() 586 cur = head; in test_guard_gap_other_gaps() 587 head = cur->next; in test_guard_gap_other_gaps() 589 free(cur); in test_guard_gap_other_gaps() 627 cur = malloc(sizeof(*cur)); in test_guard_gap_new_mappings_gaps() 630 cur->next = head; in test_guard_gap_new_mappings_gaps() 631 head = cur; in test_guard_gap_new_mappings_gaps() 641 cur = head; in test_guard_gap_new_mappings_gaps() [all …]
|
| /tools/testing/selftests/powerpc/nx-gzip/ |
| A D | gunz_test.c | 75 #define fifo_free_first_bytes(cur, used, len) ((((cur)+(used)) <= (len)) \ argument 76 ? (len)-((cur)+(used)) : 0) 77 #define fifo_free_last_bytes(cur, used, len) ((((cur)+(used)) <= (len)) \ argument 78 ? (cur) : (len)-(used)) 80 #define fifo_used_first_bytes(cur, used, len) ((((cur)+(used)) <= (len)) \ argument 81 ? (used) : (len)-(cur)) 82 #define fifo_used_last_bytes(cur, used, len) ((((cur)+(used)) <= (len)) \ argument 83 ? 0 : ((used)+(cur))-(len)) 85 #define fifo_free_first_offset(cur, used) ((cur)+(used)) argument 87 fifo_used_last_bytes(cur, used, len) [all …]
|
| /tools/testing/selftests/pcie_bwctrl/ |
| A D | set_pcie_cooling_state.sh | 46 local cur 58 cur=`cat $port/cur_state` 59 delta=$((max-cur))
|
| /tools/sched_ext/ |
| A D | scx_qmap.bpf.c | 719 u32 cap, cur; in monitor_cpuperf() local 727 cur = scx_bpf_cpuperf_cur(i); in monitor_cpuperf() 729 cur_min = cur < cur_min ? cur : cur_min; in monitor_cpuperf() 730 cur_max = cur > cur_max ? cur : cur_max; in monitor_cpuperf() 737 cur_sum += cur * cap / SCX_CPUPERF_ONE; in monitor_cpuperf() 746 cur = cpuc->cpuperf_target; in monitor_cpuperf() 747 target_sum += cur; in monitor_cpuperf() 748 target_min = cur < target_min ? cur : target_min; in monitor_cpuperf() 749 target_max = cur > target_max ? cur : target_max; in monitor_cpuperf()
|