/tools/lib/ |
D | bitmap.c | 10 unsigned int k, w = 0, lim = bits/BITS_PER_LONG; in __bitmap_weight() local 12 for (k = 0; k < lim; k++) in __bitmap_weight() 13 w += hweight_long(bitmap[k]); in __bitmap_weight() 16 w += hweight_long(bitmap[k] & BITMAP_LAST_WORD_MASK(bits)); in __bitmap_weight() 24 int k; in __bitmap_or() local 27 for (k = 0; k < nr; k++) in __bitmap_or() 28 dst[k] = bitmap1[k] | bitmap2[k]; in __bitmap_or() 63 unsigned int k; in __bitmap_and() local 67 for (k = 0; k < lim; k++) in __bitmap_and() 68 result |= (dst[k] = bitmap1[k] & bitmap2[k]); in __bitmap_and() [all …]
|
/tools/testing/selftests/ptrace/ |
D | vmaccess.c | 48 int s, k, pid = fork(); in TEST() local 59 k = ptrace(PTRACE_ATTACH, pid, 0L, 0L); in TEST() 61 ASSERT_EQ(k, -1); in TEST() 62 k = waitpid(-1, &s, WNOHANG); in TEST() 63 ASSERT_NE(k, -1); in TEST() 64 ASSERT_NE(k, 0); in TEST() 65 ASSERT_NE(k, pid); in TEST() 69 k = ptrace(PTRACE_ATTACH, pid, 0L, 0L); in TEST() 70 ASSERT_EQ(k, 0); in TEST() 71 k = waitpid(-1, &s, 0); in TEST() [all …]
|
/tools/include/linux/ |
D | jhash.h | 73 const u8 *k = key; in jhash() local 80 a += __get_unaligned_cpu32(k); in jhash() 81 b += __get_unaligned_cpu32(k + 4); in jhash() 82 c += __get_unaligned_cpu32(k + 8); in jhash() 85 k += 12; in jhash() 90 case 12: c += (u32)k[11]<<24; in jhash() 91 case 11: c += (u32)k[10]<<16; in jhash() 92 case 10: c += (u32)k[9]<<8; in jhash() 93 case 9: c += k[8]; in jhash() 94 case 8: b += (u32)k[7]<<24; in jhash() [all …]
|
/tools/testing/selftests/bpf/progs/ |
D | test_jhash.h | 39 const unsigned char *k = key; in jhash() local 44 a += *(volatile u32 *)(k); in jhash() 45 b += *(volatile u32 *)(k + 4); in jhash() 46 c += *(volatile u32 *)(k + 8); in jhash() 49 k += 12; in jhash() 52 case 12: c += (u32)k[11]<<24; in jhash() 53 case 11: c += (u32)k[10]<<16; in jhash() 54 case 10: c += (u32)k[9]<<8; in jhash() 55 case 9: c += k[8]; in jhash() 56 case 8: b += (u32)k[7]<<24; in jhash() [all …]
|
D | fentry_many_args.c | 22 int g, unsigned int h, long i, __u64 j, unsigned long k) in BPF_PROG() argument 26 i == 24 && j == 25 && k == 26; in BPF_PROG() 33 __u64 g, __u64 h, __u64 i, __u64 j, __u64 k) in BPF_PROG() argument 37 i == 24 && j == 25 && k == 26; in BPF_PROG()
|
D | fexit_many_args.c | 22 int g, unsigned int h, long i, __u64 j, unsigned long k, in BPF_PROG() argument 27 i == 24 && j == 25 && k == 26 && ret == 231; in BPF_PROG() 34 __u64 g, __u64 h, __u64 i, __u64 j, __u64 k, __u64 ret) in BPF_PROG() argument 38 i == 24 && j == 25 && k == 26 && ret == 231; in BPF_PROG()
|
D | test_l4lb.c | 60 const unsigned char *k = key; in jhash() local 65 a += *(u32 *)(k); in jhash() 66 b += *(u32 *)(k + 4); in jhash() 67 c += *(u32 *)(k + 8); in jhash() 70 k += 12; in jhash() 73 case 12: c += (u32)k[11]<<24; in jhash() 74 case 11: c += (u32)k[10]<<16; in jhash() 75 case 10: c += (u32)k[9]<<8; in jhash() 76 case 9: c += k[8]; in jhash() 77 case 8: b += (u32)k[7]<<24; in jhash() [all …]
|
D | test_l4lb_noinline.c | 56 const unsigned char *k = key; in jhash() local 61 a += *(u32 *)(k); in jhash() 62 b += *(u32 *)(k + 4); in jhash() 63 c += *(u32 *)(k + 8); in jhash() 66 k += 12; in jhash() 69 case 12: c += (u32)k[11]<<24; in jhash() 70 case 11: c += (u32)k[10]<<16; in jhash() 71 case 10: c += (u32)k[9]<<8; in jhash() 72 case 9: c += k[8]; in jhash() 73 case 8: b += (u32)k[7]<<24; in jhash() [all …]
|
D | test_l4lb_noinline_dynptr.c | 58 const unsigned char *k = key; in jhash() local 63 a += *(u32 *)(k); in jhash() 64 b += *(u32 *)(k + 4); in jhash() 65 c += *(u32 *)(k + 8); in jhash() 68 k += 12; in jhash() 71 case 12: c += (u32)k[11]<<24; in jhash() 72 case 11: c += (u32)k[10]<<16; in jhash() 73 case 10: c += (u32)k[9]<<8; in jhash() 74 case 9: c += k[8]; in jhash() 75 case 8: b += (u32)k[7]<<24; in jhash() [all …]
|
D | for_each_hash_map_elem.c | 33 __u32 k; in check_hash_elem() local 37 k = *key; in check_hash_elem() 39 if (skb->len == 10000 && k == 10 && v == 10) in check_hash_elem()
|
D | test_xdp_noinline.c | 56 const unsigned char *k = key; in jhash() local 61 a += *(u32 *)(k); in jhash() 62 b += *(u32 *)(k + 4); in jhash() 63 c += *(u32 *)(k + 8); in jhash() 66 k += 12; in jhash() 69 case 12: c += (u32)k[11]<<24; in jhash() 70 case 11: c += (u32)k[10]<<16; in jhash() 71 case 10: c += (u32)k[9]<<8; in jhash() 72 case 9: c += k[8]; in jhash() 73 case 8: b += (u32)k[7]<<24; in jhash() [all …]
|
/tools/testing/selftests/bpf/prog_tests/ |
D | hashmap.c | 14 static size_t hash_fn(long k, void *ctx) in hash_fn() argument 16 return k; in hash_fn() 56 long oldk, k = i; in test_hashmap_generic() local 59 err = hashmap__update(map, k, v, &oldk, &oldv); in test_hashmap_generic() 65 err = hashmap__add(map, k, v); in test_hashmap_generic() 67 err = hashmap__set(map, k, v, &oldk, &oldv); in test_hashmap_generic() 73 if (CHECK(err, "elem_add", "failed to add k/v %ld = %ld: %d\n", k, v, err)) in test_hashmap_generic() 76 if (CHECK(!hashmap__find(map, k, &oldv), "elem_find", in test_hashmap_generic() 77 "failed to find key %ld\n", k)) in test_hashmap_generic() 93 long k = entry->key; in test_hashmap_generic() local [all …]
|
/tools/perf/tests/ |
D | event_groups.c | 81 static int run_test(int i, int j, int k) in run_test() argument 83 int erroneous = ((((1 << i) | (1 << j) | (1 << k)) & 5) == 5); in run_test() 96 sibling_fd2 = event_open(types[k], configs[k], group_fd); in run_test() 111 int i, j, k; in test__event_groups() local 122 for (k = 0; k < 3; k++) { in test__event_groups() 123 r = run_test(i, j, k); in test__event_groups() 129 types[k], configs[k], r ? "Fail" : "Pass"); in test__event_groups()
|
D | hists_link.c | 72 size_t i = 0, k; in add_hist_entries() local 83 for (k = 0; k < ARRAY_SIZE(fake_common_samples); k++) { in add_hist_entries() 85 sample.pid = fake_common_samples[k].pid; in add_hist_entries() 86 sample.tid = fake_common_samples[k].pid; in add_hist_entries() 87 sample.ip = fake_common_samples[k].ip; in add_hist_entries() 98 thread__put(fake_common_samples[k].thread); in add_hist_entries() 99 fake_common_samples[k].thread = thread__get(al.thread); in add_hist_entries() 100 map__put(fake_common_samples[k].map); in add_hist_entries() 101 fake_common_samples[k].map = map__get(al.map); in add_hist_entries() 102 fake_common_samples[k].sym = al.sym; in add_hist_entries() [all …]
|
D | builtin-test.c | 263 #define for_each_test(j, k, t) \ argument 264 for (j = 0, k = 0; j < ARRAY_SIZE(tests); j++, k = 0) \ 265 while ((t = tests[j][k++]) != NULL) 370 unsigned int j, k; in __cmd_test() local 374 for_each_test(j, k, t) { in __cmd_test() 381 for_each_test(j, k, t) { in __cmd_test() 474 unsigned int j, k; in perf_test__list() local 478 for_each_test(j, k, t) { in perf_test__list()
|
D | hists_common.c | 128 size_t k; in setup_fake_machine() local 138 for (k = 0; k < fake_symbols[i].nr_syms; k++) { in setup_fake_machine() 140 struct fake_sym *fsym = &fake_symbols[i].syms[k]; in setup_fake_machine()
|
/tools/testing/selftests/tc-testing/ |
D | tdc_helper.py | 64 for k in tcase.keys(): 65 if (isinstance(tcase[k], list)): 66 print(k + ":") 67 print_list(tcase[k]) 69 if not ((k == 'id') or (k == 'name')): 70 print(k + ": " + str(tcase[k]))
|
/tools/testing/radix-tree/ |
D | multiorder.c | 98 int k; in multiorder_tagged_iteration() local 101 for (k = i; index[k] < tag_index[i]; k++) in multiorder_tagged_iteration() 103 if (j <= (index[k] | ((1 << order[k]) - 1))) in multiorder_tagged_iteration() 110 for (k = i; index[k] < tag_index[i]; k++) in multiorder_tagged_iteration() 112 mask = (1UL << order[k]) - 1; in multiorder_tagged_iteration() 117 assert(item->order == order[k]); in multiorder_tagged_iteration() 126 int mask, k; in multiorder_tagged_iteration() local 129 for (k = i; index[k] < tag_index[i]; k++) in multiorder_tagged_iteration() 131 if (j <= (index[k] | ((1 << order[k]) - 1))) in multiorder_tagged_iteration() 137 for (k = i; index[k] < tag_index[i]; k++) in multiorder_tagged_iteration() [all …]
|
/tools/include/uapi/linux/ |
D | filter.h | 28 __u32 k; /* Generic multiuse field */ member 49 #define BPF_STMT(code, k) { (unsigned short)(code), 0, 0, k } argument 52 #define BPF_JUMP(code, k, jt, jf) { (unsigned short)(code), jt, jf, k } argument
|
/tools/testing/selftests/net/ |
D | devlink_port_split.py | 107 def split(k, port, should_fail=False): argument 115 cmd = "devlink port split %s count %s" % (port.bus_info, k) 121 return create_split_group(port, k) 124 return create_split_group(port, k) 183 def create_split_group(port, k): argument 189 return list(port.name + "s" + str(i) for i in range(k)) 192 def split_unsplittable_port(port, k): argument 198 new_split_group = split(k, port, should_fail=True) 204 def split_splittable_port(port, k, lanes, dev): argument 209 new_split_group = split(k, port) [all …]
|
/tools/testing/selftests/netfilter/ |
D | audit_logread.c | 99 char *k, *v; in readlog() local 110 while ((k = strtok(NULL, "="))) { in readlog() 114 if (!strcmp(k, "pid") || in readlog() 115 !strcmp(k, "comm") || in readlog() 116 !strcmp(k, "subj")) in readlog() 120 if (!strcmp(k, "table")) in readlog() 123 printf("%s%s=%s", sep, k, v); in readlog()
|
/tools/thermal/tmon/ |
D | sysfs.c | 285 int i, j, n, k = 0; in scan_tzones() local 304 sysfs_get_string(tz_name, "type", ptdata.tzi[k].type); in scan_tzones() 305 ptdata.tzi[k].instance = i; in scan_tzones() 308 ptdata.tzi[k].nr_cdev = 0; in scan_tzones() 309 ptdata.tzi[k].nr_trip_pts = 0; in scan_tzones() 314 &ptdata.tzi[k], k)) in scan_tzones() 322 &ptdata.tzi[k], i, j)) in scan_tzones() 331 ptdata.tzi[k].nr_cdev); in scan_tzones() 332 k++; in scan_tzones() 343 int i, n, k = 0; in scan_cdevs() local [all …]
|
/tools/testing/selftests/tc-testing/plugin-lib/ |
D | scapyPlugin.py | 40 for k in scapy_keys: 41 if k not in scapyinfo: 43 missing_keys.append(k)
|
/tools/lib/perf/ |
D | cpumap.c | 409 int i, j, k; in perf_cpu_map__merge() local 425 i = j = k = 0; in perf_cpu_map__merge() 430 tmp_cpus[k++] = __perf_cpu_map__cpu(orig, i++); in perf_cpu_map__merge() 432 tmp_cpus[k++] = __perf_cpu_map__cpu(other, j++); in perf_cpu_map__merge() 436 tmp_cpus[k++] = __perf_cpu_map__cpu(orig, i++); in perf_cpu_map__merge() 439 tmp_cpus[k++] = __perf_cpu_map__cpu(other, j++); in perf_cpu_map__merge() 440 assert(k <= tmp_len); in perf_cpu_map__merge() 442 merged = cpu_map__trim_new(k, tmp_cpus); in perf_cpu_map__merge() 453 int i, j, k; in perf_cpu_map__intersect() local 466 i = j = k = 0; in perf_cpu_map__intersect() [all …]
|
/tools/iio/ |
D | iio_generic_buffer.c | 186 int k; in process_scan() local 188 for (k = 0; k < num_channels; k++) in process_scan() 189 switch (channels[k].bytes) { in process_scan() 192 print1byte(*(uint8_t *)(data + channels[k].location), in process_scan() 193 &channels[k]); in process_scan() 196 print2byte(*(uint16_t *)(data + channels[k].location), in process_scan() 197 &channels[k]); in process_scan() 200 print4byte(*(uint32_t *)(data + channels[k].location), in process_scan() 201 &channels[k]); in process_scan() 204 print8byte(*(uint64_t *)(data + channels[k].location), in process_scan() [all …]
|