/linux/tools/testing/selftests/bpf/progs/ |
H A D | wq_failures.c | 21 } array SEC(".maps"); 58 val = bpf_map_lookup_elem(&array, &key); in __flag() 83 val = bpf_map_lookup_elem(&array, &key); in __flag() 107 wq = bpf_map_lookup_elem(&array, &key); in test_wrong_wq_pointer() 111 if (bpf_wq_init(wq, &array, 0)) in test_wrong_wq_pointer() 133 wq = bpf_map_lookup_elem(&array, &key); in test_wrong_wq_pointer_offset() 137 if (bpf_wq_init(wq, &array, 0)) in test_wrong_wq_pointer_offset()
|
/linux/fs/dlm/ |
H A D | member.c | 73 if (array) { in log_slots() 75 if (!array[i].nodeid) in log_slots() 79 array[i].slot, array[i].nodeid); in log_slots() 214 array = kcalloc(array_size, sizeof(*array), GFP_NOFS); in dlm_slots_assign() 215 if (!array) in dlm_slots_assign() 228 kfree(array); in dlm_slots_assign() 260 kfree(array); in dlm_slots_assign() 275 kfree(array); in dlm_slots_assign() 280 *slots_out = array; in dlm_slots_assign() 428 array = kmalloc_array(total, sizeof(*array), GFP_NOFS); in make_member_array() [all …]
|
/linux/fs/nfs/ |
H A D | dir.c | 209 array->size = 0; in nfs_readdir_folio_init_array() 226 kfree(array->array[i].name); in nfs_readdir_clear_array() 257 return array->size == 0 ? array->last_cookie : array->array[0].cookie; in nfs_readdir_array_index_cookie() 329 cache_entry = &array->array[array->size]; in nfs_readdir_folio_array_append() 338 array->size++; in nfs_readdir_folio_array_append() 513 desc->dir_cookie = array->array[index].cookie; in nfs_readdir_search_for_pos() 529 if (array->size && cookie < array->array[0].cookie) in nfs_readdir_array_cookie_in_range() 544 if (array->array[i].cookie == desc->dir_cookie) { in nfs_readdir_search_for_cookie() 1103 ent = &array->array[i]; in nfs_do_filldir() 1114 desc->dir_cookie = array->array[i + 1].cookie; in nfs_do_filldir() [all …]
|
/linux/tools/perf/util/ |
H A D | bpf_off_cpu.c | 36 u64 array[1024 / sizeof(u64)]; member 342 data.array[n++] = sid; in off_cpu_write() 350 data.array[n++] = tstamp; in off_cpu_write() 352 data.array[n++] = sid; in off_cpu_write() 354 data.array[n++] = 0; in off_cpu_write() 356 data.array[n++] = val; in off_cpu_write() 362 data.array[n + 2] = 0; in off_cpu_write() 365 while (data.array[n + 2 + len]) in off_cpu_write() 369 data.array[n] = len + 1; in off_cpu_write() 373 data.array[ip_pos] = data.array[n + 2]; in off_cpu_write() [all …]
|
/linux/Documentation/admin-guide/ |
H A D | md.rst | 22 or, to assemble a partitionable array:: 44 level of the RAID array 155 The array is started with the RUN_ARRAY ioctl. 162 array using HOT_REMOVE_DISK. 168 An array can be ``created`` by describing the array (level, chunksize 174 and its role in the array. 208 be set while assembling an array. 276 array creation it will default to 0, though starting the array as 399 degraded array, or if the array becomes degraded during a write. 573 the array, either before the array is activated, or before [all …]
|
/linux/sound/soc/intel/avs/ |
H A D | debugfs.c | 143 u32 *array, num_elems; in probe_points_write() local 147 ret = parse_int_array_user(from, count, (int **)&array); in probe_points_write() 151 num_elems = *array; in probe_points_write() 152 bytes = sizeof(*array) * num_elems; in probe_points_write() 158 desc = (struct avs_probe_point_desc *)&array[1]; in probe_points_write() 165 kfree(array); in probe_points_write() 181 u32 *array, num_elems; in probe_points_disconnect_write() local 185 ret = parse_int_array_user(from, count, (int **)&array); in probe_points_disconnect_write() 189 num_elems = *array; in probe_points_disconnect_write() 190 bytes = sizeof(*array) * num_elem in probe_points_disconnect_write() 369 u32 *array, num_elems; trace_control_write() local [all...] |
/linux/tools/lib/perf/tests/ |
H A D | test-threadmap.c | 14 static int test_threadmap_array(int nr, pid_t *array) in test_threadmap_array() argument 19 threads = perf_thread_map__new_array(nr, array); in test_threadmap_array() 26 perf_thread_map__pid(threads, i) == (array ? array[i] : -1)); in test_threadmap_array() 33 perf_thread_map__pid(threads, 0) == (array ? array[0] : -1)); in test_threadmap_array()
|
/linux/tools/testing/radix-tree/ |
H A D | iteration_check_2.c | 57 DEFINE_XARRAY(array); in iteration_test2() 64 xa_store(&array, 100, xa_mk_value(100), GFP_KERNEL); in iteration_test2() 65 xa_set_mark(&array, 100, XA_MARK_0); in iteration_test2() 67 if (pthread_create(&threads[0], NULL, iterator, &array)) { in iteration_test2() 71 if (pthread_create(&threads[1], NULL, throbber, &array)) { in iteration_test2() 86 xa_destroy(&array); in iteration_test2()
|
H A D | iteration_check.c | 17 static DEFINE_XARRAY(array); 54 my_item_insert(&array, pgoff); in add_entries_fn() 69 XA_STATE(xas, &array, 0); in tagged_iteration_fn() 102 XA_STATE(xas, &array, 0); in untagged_iteration_fn() 143 item = xa_erase(&array, pgoff); in remove_entries_fn() 158 tag_tagged_items(&array, 0, MAX_IDX, 10, TAG, NEW_TAG); in tag_entries_fn() 209 item_kill_tree(&array); in iteration_test()
|
/linux/Documentation/core-api/ |
H A D | assoc_array.rst | 25 already in the array will replace the old object. 60 array is rooted on the following structure:: 170 1. Initialise an associative array:: 202 3. Delete an object from an associative array:: 217 not found within the array. 225 assoc_array_clear(struct assoc_array *array, 250 of the array. 253 6. Garbage collect an associative array:: 295 This may be used on an array at the same time as the array is being 307 2. Find an object in an associative array:: [all …]
|
/linux/tools/virtio/ringtest/ |
H A D | ptr_ring.c | 115 static struct ptr_ring array ____cacheline_aligned_in_smp; 120 int ret = ptr_ring_init(&array, ring_size, 0); in alloc_ring() 124 array.batch = param; in alloc_ring() 132 ret = __ptr_ring_produce(&array, buf); in add_inbuf() 151 if (tailcnt == headcnt || __ptr_ring_full(&array)) in get_buf() 163 return (tailcnt == headcnt || __ptr_ring_full(&array)); in used_empty() 194 return __ptr_ring_empty(&array); in avail_empty() 201 ptr = __ptr_ring_consume(&array); in use_buf()
|
/linux/net/netfilter/ |
H A D | nf_conntrack_ftp.c | 123 memset(array, 0, sizeof(array[0])*array_size); in try_number() 128 array[i] = array[i]*10 + *data - '0'; in try_number() 155 u_int32_t array[6]; in try_rfc959() local 157 length = try_number(data, dlen, array, 6, ',', term); in try_rfc959() 161 cmd->u3.ip = htonl((array[0] << 24) | (array[1] << 16) | in try_rfc959() 162 (array[2] << 8) | array[3]); in try_rfc959() 163 cmd->u.tcp.port = htons((array[4] << 8) | array[5]); in try_rfc959() 248 u_int32_t array[4]; in try_eprt() local 251 length = try_number(data + 3, dlen - 3, array, 4, '.', delim); in try_eprt() 253 cmd->u3.ip = htonl((array[0] << 24) | (array[1] << 16) in try_eprt() [all …]
|
/linux/arch/x86/kvm/ |
H A D | cpuid.c | 837 static struct kvm_cpuid_entry2 *get_next_cpuid(struct kvm_cpuid_array *array) in get_next_cpuid() argument 839 if (array->nent >= array->maxnent) in get_next_cpuid() 842 return &array->entries[array->nent++]; in get_next_cpuid() 845 static struct kvm_cpuid_entry2 *do_host_cpuid(struct kvm_cpuid_array *array, in do_host_cpuid() argument 848 struct kvm_cpuid_entry2 *entry = get_next_cpuid(array); in do_host_cpuid() 888 static int __do_cpuid_func_emulated(struct kvm_cpuid_array *array, u32 func) in __do_cpuid_func_emulated() argument 892 if (array->nent >= array in __do_cpuid_func_emulated() 923 __do_cpuid_func(struct kvm_cpuid_array * array,u32 function) __do_cpuid_func() argument 1352 do_cpuid_func(struct kvm_cpuid_array * array,u32 func,unsigned int type) do_cpuid_func() argument 1363 get_cpuid_func(struct kvm_cpuid_array * array,u32 func,unsigned int type) get_cpuid_func() argument 1422 struct kvm_cpuid_array array = { kvm_dev_ioctl_get_cpuid() local [all...] |
/linux/Documentation/bpf/ |
H A D | map_array.rst | 12 ``BPF_MAP_TYPE_ARRAY`` and ``BPF_MAP_TYPE_PERCPU_ARRAY`` provide generic array 14 of constant size. The size of the array is defined in ``max_entries`` at 15 creation time. All array elements are pre-allocated and zero initialized when 18 stored can be of any size, however, all array elements are aligned to 8 24 memory are allocated to store all array values, starting on the second page, 106 This snippet shows how to declare an array in a BPF program. 118 This example BPF program shows how to access an array element. 167 This snippet shows how to initialize the elements of an array. 187 This snippet shows how to retrieve an element value from an array. 210 This snippet shows how to initialize the elements of a per CPU array. [all …]
|
/linux/drivers/md/bcache/ |
H A D | util.h | 251 #define array_alloc(array) \ argument 253 typeof((array)->freelist) _ret = (array)->freelist; \ 256 (array)->freelist = *((typeof((array)->freelist) *) _ret);\ 265 *((typeof((array)->freelist) *) _ptr) = (array)->freelist; \ 266 (array)->freelist = _ptr; \ 271 typeof((array)->freelist) _i; \ 274 (array)->freelist = NULL; \ 276 for (_i = (array)->data; \ 277 _i < (array)->data + ARRAY_SIZE((array)->data); \ 279 array_free(array, _i); \ [all …]
|
/linux/lib/ |
H A D | assoc_array.c | 445 array->root = NULL; in assoc_array_destroy() 983 edit->array = array; in assoc_array_insert() 1095 edit->array = array; in assoc_array_delete() 1281 if (!array->root) in assoc_array_clear() 1287 edit->array = array; in assoc_array_clear() 1289 edit->set[1].ptr = &array->root; in assoc_array_clear() 1373 if (edit->array->root == NULL) { in assoc_array_apply_edit() 1469 if (!array->root) in assoc_array_gc() 1475 edit->array = array; in assoc_array_gc() 1478 edit->set[0].ptr = &array->root; in assoc_array_gc() [all …]
|
H A D | string_helpers.c | 177 *array = ints; in parse_int_array_user() 791 if (!array) in kfree_strarray() 795 kfree(array[i]); in kfree_strarray() 796 kfree(array); in kfree_strarray() 801 char **array; member 807 struct strarray *array = res; in devm_kfree_strarray() local 809 kfree_strarray(array->array, array->n); in devm_kfree_strarray() 821 if (!ptr->array) { in devm_kasprintf_strarray() 829 return ptr->array; in devm_kasprintf_strarray() 923 item = array[index]; in match_string() [all …]
|
/linux/tools/perf/arch/x86/util/ |
H A D | event.c | 96 const __u64 *array, u64 type) in arch_perf_parse_sample_weight() argument 100 weight.full = *array; in arch_perf_parse_sample_weight() 111 __u64 *array, u64 type) in arch_perf_synthesize_sample_weight() argument 113 *array = data->weight; in arch_perf_synthesize_sample_weight() 116 *array &= 0xffffffff; in arch_perf_synthesize_sample_weight() 117 *array |= ((u64)data->ins_lat << 32); in arch_perf_synthesize_sample_weight() 118 *array |= ((u64)data->retire_lat << 48); in arch_perf_synthesize_sample_weight()
|
/linux/drivers/target/iscsi/ |
H A D | iscsi_target_seq_pdu_list.c | 99 array[0] = 0; in iscsit_create_random_array() 109 if ((array[k] & 0x80000000) && (array[k] == j)) in iscsit_create_random_array() 112 array[i] = j; in iscsit_create_random_array() 116 array[i] &= ~0x80000000; in iscsit_create_random_array() 133 if (!array) { in iscsit_randomize_pdu_lists() 143 kfree(array); in iscsit_randomize_pdu_lists() 153 if (!array) { in iscsit_randomize_pdu_lists() 163 kfree(array); in iscsit_randomize_pdu_lists() 174 u32 *array, seq_count = cmd->seq_count; in iscsit_randomize_seq_lists() local 185 if (!array) { in iscsit_randomize_seq_lists() [all …]
|
/linux/include/linux/ |
H A D | skb_array.h | 107 struct sk_buff **array, int n) in skb_array_consume_batched() argument 109 return ptr_ring_consume_batched(&a->ring, (void **)array, n); in skb_array_consume_batched() 118 struct sk_buff **array, int n) in skb_array_consume_batched_irq() argument 120 return ptr_ring_consume_batched_irq(&a->ring, (void **)array, n); in skb_array_consume_batched_irq() 129 struct sk_buff **array, int n) in skb_array_consume_batched_any() argument 131 return ptr_ring_consume_batched_any(&a->ring, (void **)array, n); in skb_array_consume_batched_any() 141 struct sk_buff **array, int n) in skb_array_consume_batched_bh() argument 143 return ptr_ring_consume_batched_bh(&a->ring, (void **)array, n); in skb_array_consume_batched_bh()
|
/linux/tools/perf/trace/beauty/ |
H A D | beauty.h | 17 #define DEFINE_STRARRAY(array, _prefix) struct strarray strarray__##array = { \ argument 18 .nr_entries = ARRAY_SIZE(array), \ 19 .entries = array, \ 23 #define DEFINE_STRARRAY_OFFSET(array, _prefix, off) struct strarray strarray__##array = { \ argument 25 .nr_entries = ARRAY_SIZE(array), \ 26 .entries = array, \ 52 #define DEFINE_STRARRAYS(array) struct strarrays strarrays__##array = { \ argument 53 .nr_entries = ARRAY_SIZE(array), \ 54 .entries = array, \
|
/linux/Documentation/translations/zh_CN/core-api/ |
H A D | assoc_array.rst | 162 void assoc_array_init(struct assoc_array *array); 170 assoc_array_insert(struct assoc_array *array, 191 assoc_array_delete(struct assoc_array *array, 208 assoc_array_clear(struct assoc_array *array, 221 void assoc_array_destroy(struct assoc_array *array, 232 int assoc_array_gc(struct assoc_array *array, 258 int assoc_array_iterate(const struct assoc_array *array, 274 void *assoc_array_find(const struct assoc_array *array,
|
/linux/arch/s390/include/asm/ |
H A D | ctlreg.h | 91 #define __local_ctl_load(low, high, array) do { \ argument 93 char _[sizeof(array)]; \ 101 typecheck(struct ctlreg, array[0]); \ 105 : [_arr] "Q" (*(struct addrtype *)(&array)), \ 110 #define __local_ctl_store(low, high, array) do { \ argument 112 char _[sizeof(array)]; \ 120 typecheck(struct ctlreg, array[0]); \ 123 : [_arr] "=Q" (*(struct addrtype *)(&array)) \
|
/linux/fs/befs/ |
H A D | datastream.c | 255 const befs_block_run *array = data->direct; in befs_find_brun_direct() local 261 sum += array[i].len, i++) { in befs_find_brun_direct() 265 run->allocation_group = array[i].allocation_group; in befs_find_brun_direct() 266 run->start = array[i].start + offset; in befs_find_brun_direct() 267 run->len = array[i].len - offset; in befs_find_brun_direct() 315 befs_disk_block_run *array; in befs_find_brun_indirect() local 337 array = (befs_disk_block_run *) indirblock->b_data; in befs_find_brun_indirect() 340 int len = fs16_to_cpu(sb, array[j].len); in befs_find_brun_indirect() 345 fs32_to_cpu(sb, array[j].allocation_group); in befs_find_brun_indirect() 347 fs16_to_cpu(sb, array[j].start) + offset; in befs_find_brun_indirect() [all …]
|
/linux/Documentation/devicetree/bindings/arm/ |
H A D | vexpress-config.yaml | 35 $ref: /schemas/types.yaml#/definitions/uint32-array 53 $ref: /schemas/types.yaml#/definitions/uint32-array 71 $ref: /schemas/types.yaml#/definitions/uint32-array 89 $ref: /schemas/types.yaml#/definitions/uint32-array 117 $ref: /schemas/types.yaml#/definitions/uint32-array 123 $ref: /schemas/types.yaml#/definitions/uint32-array 148 $ref: /schemas/types.yaml#/definitions/uint32-array 169 $ref: /schemas/types.yaml#/definitions/uint32-array 190 $ref: /schemas/types.yaml#/definitions/uint32-array 211 $ref: /schemas/types.yaml#/definitions/uint32-array [all …]
|