/Linux-v5.4/drivers/misc/vmw_vmci/ |
D | vmci_handle_array.c | 19 struct vmci_handle_arr *array; in vmci_handle_arr_create() local 28 array = kmalloc(handle_arr_calc_size(capacity), GFP_ATOMIC); in vmci_handle_arr_create() 29 if (!array) in vmci_handle_arr_create() 32 array->capacity = capacity; in vmci_handle_arr_create() 33 array->max_capacity = max_capacity; in vmci_handle_arr_create() 34 array->size = 0; in vmci_handle_arr_create() 36 return array; in vmci_handle_arr_create() 39 void vmci_handle_arr_destroy(struct vmci_handle_arr *array) in vmci_handle_arr_destroy() argument 41 kfree(array); in vmci_handle_arr_destroy() 47 struct vmci_handle_arr *array = *array_ptr; in vmci_handle_arr_append_entry() local [all …]
|
D | vmci_handle_array.h | 33 void vmci_handle_arr_destroy(struct vmci_handle_arr *array); 36 struct vmci_handle vmci_handle_arr_remove_entry(struct vmci_handle_arr *array, 39 struct vmci_handle vmci_handle_arr_remove_tail(struct vmci_handle_arr *array); 41 vmci_handle_arr_get_entry(const struct vmci_handle_arr *array, u32 index); 42 bool vmci_handle_arr_has_entry(const struct vmci_handle_arr *array, 44 struct vmci_handle *vmci_handle_arr_get_handles(struct vmci_handle_arr *array); 47 const struct vmci_handle_arr *array) in vmci_handle_arr_get_size() argument 49 return array->size; in vmci_handle_arr_get_size()
|
/Linux-v5.4/drivers/dma-buf/ |
D | dma-fence-array.c | 28 static void dma_fence_array_set_pending_error(struct dma_fence_array *array, in dma_fence_array_set_pending_error() argument 36 cmpxchg(&array->base.error, PENDING_ERROR, error); in dma_fence_array_set_pending_error() 39 static void dma_fence_array_clear_pending_error(struct dma_fence_array *array) in dma_fence_array_clear_pending_error() argument 42 cmpxchg(&array->base.error, PENDING_ERROR, 0); in dma_fence_array_clear_pending_error() 47 struct dma_fence_array *array = container_of(wrk, typeof(*array), work); in irq_dma_fence_array_work() local 49 dma_fence_array_clear_pending_error(array); in irq_dma_fence_array_work() 51 dma_fence_signal(&array->base); in irq_dma_fence_array_work() 52 dma_fence_put(&array->base); in irq_dma_fence_array_work() 60 struct dma_fence_array *array = array_cb->array; in dma_fence_array_cb_func() local 62 dma_fence_array_set_pending_error(array, f->error); in dma_fence_array_cb_func() [all …]
|
/Linux-v5.4/sound/hda/ |
D | array.c | 19 void *snd_array_new(struct snd_array *array) in snd_array_new() argument 21 if (snd_BUG_ON(!array->elem_size)) in snd_array_new() 23 if (array->used >= array->alloced) { in snd_array_new() 24 int num = array->alloced + array->alloc_align; in snd_array_new() 25 int oldsize = array->alloced * array->elem_size; in snd_array_new() 26 int size = (num + 1) * array->elem_size; in snd_array_new() 30 nlist = krealloc(array->list, size, GFP_KERNEL); in snd_array_new() 34 array->list = nlist; in snd_array_new() 35 array->alloced = num; in snd_array_new() 37 return snd_array_elem(array, array->used++); in snd_array_new() [all …]
|
/Linux-v5.4/kernel/bpf/ |
D | arraymap.c | 19 static void bpf_array_free_percpu(struct bpf_array *array) in bpf_array_free_percpu() argument 23 for (i = 0; i < array->map.max_entries; i++) { in bpf_array_free_percpu() 24 free_percpu(array->pptrs[i]); in bpf_array_free_percpu() 29 static int bpf_array_alloc_percpu(struct bpf_array *array) in bpf_array_alloc_percpu() argument 34 for (i = 0; i < array->map.max_entries; i++) { in bpf_array_alloc_percpu() 35 ptr = __alloc_percpu_gfp(array->elem_size, 8, in bpf_array_alloc_percpu() 38 bpf_array_free_percpu(array); in bpf_array_alloc_percpu() 41 array->pptrs[i] = ptr; in bpf_array_alloc_percpu() 79 struct bpf_array *array; in array_map_alloc() local 104 array_size = sizeof(*array); in array_map_alloc() [all …]
|
D | reuseport_array.c | 51 struct reuseport_array *array = reuseport_array(map); in reuseport_array_lookup_elem() local 54 if (unlikely(index >= array->map.max_entries)) in reuseport_array_lookup_elem() 57 return rcu_dereference(array->ptrs[index]); in reuseport_array_lookup_elem() 63 struct reuseport_array *array = reuseport_array(map); in reuseport_array_delete_elem() local 71 if (!rcu_access_pointer(array->ptrs[index])) in reuseport_array_delete_elem() 76 sk = rcu_dereference_protected(array->ptrs[index], in reuseport_array_delete_elem() 81 RCU_INIT_POINTER(array->ptrs[index], NULL); in reuseport_array_delete_elem() 95 struct reuseport_array *array = reuseport_array(map); in reuseport_array_free() local 128 sk = rcu_dereference(array->ptrs[i]); in reuseport_array_free() 138 RCU_INIT_POINTER(array->ptrs[i], NULL); in reuseport_array_free() [all …]
|
/Linux-v5.4/drivers/infiniband/hw/mthca/ |
D | mthca_allocator.c | 118 void *mthca_array_get(struct mthca_array *array, int index) in mthca_array_get() argument 122 if (array->page_list[p].page) in mthca_array_get() 123 return array->page_list[p].page[index & MTHCA_ARRAY_MASK]; in mthca_array_get() 128 int mthca_array_set(struct mthca_array *array, int index, void *value) in mthca_array_set() argument 133 if (!array->page_list[p].page) in mthca_array_set() 134 array->page_list[p].page = (void **) get_zeroed_page(GFP_ATOMIC); in mthca_array_set() 136 if (!array->page_list[p].page) in mthca_array_set() 139 array->page_list[p].page[index & MTHCA_ARRAY_MASK] = value; in mthca_array_set() 140 ++array->page_list[p].used; in mthca_array_set() 145 void mthca_array_clear(struct mthca_array *array, int index) in mthca_array_clear() argument [all …]
|
/Linux-v5.4/drivers/ras/ |
D | cec.c | 95 u64 *array; /* container page */ member 147 u8 decay = DECAY(ca->array[i]); in do_spring_cleaning() 154 ca->array[i] &= ~(DECAY_MASK << COUNT_BITS); in do_spring_cleaning() 155 ca->array[i] |= (decay << COUNT_BITS); in do_spring_cleaning() 194 this_pfn = PFN(ca->array[i]); in __find_elem() 238 memmove((void *)&ca->array[idx], in del_elem() 239 (void *)&ca->array[idx + 1], in del_elem() 251 unsigned int this = FULL_COUNT(ca->array[i]); in del_lru_elem_unlocked() 261 return PFN(ca->array[min_idx]); in del_lru_elem_unlocked() 290 u64 this = PFN(ca->array[i]); in sanity_check() [all …]
|
/Linux-v5.4/include/linux/ |
D | assoc_array.h | 54 static inline void assoc_array_init(struct assoc_array *array) in assoc_array_init() argument 56 array->root = NULL; in assoc_array_init() 57 array->nr_leaves_on_tree = 0; in assoc_array_init() 60 extern int assoc_array_iterate(const struct assoc_array *array, 64 extern void *assoc_array_find(const struct assoc_array *array, 67 extern void assoc_array_destroy(struct assoc_array *array, 69 extern struct assoc_array_edit *assoc_array_insert(struct assoc_array *array, 75 extern struct assoc_array_edit *assoc_array_delete(struct assoc_array *array, 78 extern struct assoc_array_edit *assoc_array_clear(struct assoc_array *array, 82 extern int assoc_array_gc(struct assoc_array *array,
|
/Linux-v5.4/arch/s390/tools/ |
D | gen_facilities.c | 126 unsigned long long *array; in print_facility_list() local 128 array = calloc(1, 8); in print_facility_list() 129 if (!array) in print_facility_list() 136 array = realloc(array, (dword + 1) * 8); in print_facility_list() 137 if (!array) in print_facility_list() 139 memset(array + high + 1, 0, (dword - high) * 8); in print_facility_list() 142 array[dword] |= 1ULL << bit; in print_facility_list() 146 printf("_AC(0x%016llx,UL)%c", array[i], i < high ? ',' : '\n'); in print_facility_list() 147 free(array); in print_facility_list()
|
/Linux-v5.4/drivers/scsi/isci/ |
D | unsolicited_frame_control.c | 85 uf_control->headers.array = virt + SCI_UFI_BUF_SIZE; in sci_unsolicited_frame_control_construct() 95 uf_control->address_table.array = virt + SCI_UFI_BUF_SIZE + SCI_UFI_HDR_SIZE; in sci_unsolicited_frame_control_construct() 110 uf = &uf_control->buffers.array[i]; in sci_unsolicited_frame_control_construct() 112 uf_control->address_table.array[i] = dma; in sci_unsolicited_frame_control_construct() 115 uf->header = &uf_control->headers.array[i]; in sci_unsolicited_frame_control_construct() 136 *frame_header = &uf_control->buffers.array[frame_index].header->data; in sci_unsolicited_frame_control_get_header() 149 *frame_buffer = uf_control->buffers.array[frame_index].buffer; in sci_unsolicited_frame_control_get_buffer() 171 while (lower_32_bits(uf_control->address_table.array[frame_get]) == 0 && in sci_unsolicited_frame_control_release_frame() 172 upper_32_bits(uf_control->address_table.array[frame_get]) == 0 && in sci_unsolicited_frame_control_release_frame() 184 uf_control->buffers.array[frame_index].state = UNSOLICITED_FRAME_RELEASED; in sci_unsolicited_frame_control_release_frame() [all …]
|
/Linux-v5.4/drivers/media/usb/gspca/stv06xx/ |
D | stv06xx_hdcs.c | 66 } array; member 287 if (width > hdcs->array.width) in hdcs_set_size() 288 width = hdcs->array.width; in hdcs_set_size() 292 if (height + 2 * hdcs->array.border + HDCS_1020_BOTTOM_Y_SKIP in hdcs_set_size() 293 > hdcs->array.height) in hdcs_set_size() 294 height = hdcs->array.height - 2 * hdcs->array.border - in hdcs_set_size() 297 y = (hdcs->array.height - HDCS_1020_BOTTOM_Y_SKIP - height) / 2 in hdcs_set_size() 298 + hdcs->array.top; in hdcs_set_size() 300 if (height > hdcs->array.height) in hdcs_set_size() 301 height = hdcs->array.height; in hdcs_set_size() [all …]
|
/Linux-v5.4/tools/perf/util/ |
D | evsel.c | 1848 const __u64 *array = event->sample.array; in perf_evsel__parse_id_sample() local 1852 array += ((event->header.size - in perf_evsel__parse_id_sample() 1856 sample->id = *array; in perf_evsel__parse_id_sample() 1857 array--; in perf_evsel__parse_id_sample() 1861 u.val64 = *array; in perf_evsel__parse_id_sample() 1869 array--; in perf_evsel__parse_id_sample() 1873 sample->stream_id = *array; in perf_evsel__parse_id_sample() 1874 array--; in perf_evsel__parse_id_sample() 1878 sample->id = *array; in perf_evsel__parse_id_sample() 1879 array--; in perf_evsel__parse_id_sample() [all …]
|
D | parse-events.y | 96 %type <array> array 97 %type <array> array_term 98 %type <array> array_terms 110 struct parse_events_array array; member 623 PE_NAME array '=' PE_NAME 630 term->array = $2; 634 PE_NAME array '=' PE_VALUE 640 term->array = $2; 653 array: 688 struct parse_events_array array; variable [all …]
|
D | synthetic-events.c | 1237 __u64 *array; in perf_event__synthesize_sample() local 1245 array = event->sample.array; in perf_event__synthesize_sample() 1248 *array = sample->id; in perf_event__synthesize_sample() 1249 array++; in perf_event__synthesize_sample() 1253 *array = sample->ip; in perf_event__synthesize_sample() 1254 array++; in perf_event__synthesize_sample() 1260 *array = u.val64; in perf_event__synthesize_sample() 1261 array++; in perf_event__synthesize_sample() 1265 *array = sample->time; in perf_event__synthesize_sample() 1266 array++; in perf_event__synthesize_sample() [all …]
|
/Linux-v5.4/drivers/gpio/ |
D | gpiolib-legacy.c | 85 int gpio_request_array(const struct gpio *array, size_t num) in gpio_request_array() argument 89 for (i = 0; i < num; i++, array++) { in gpio_request_array() 90 err = gpio_request_one(array->gpio, array->flags, array->label); in gpio_request_array() 98 gpio_free((--array)->gpio); in gpio_request_array() 108 void gpio_free_array(const struct gpio *array, size_t num) in gpio_free_array() argument 111 gpio_free((array++)->gpio); in gpio_free_array()
|
/Linux-v5.4/Documentation/RCU/ |
D | arrayRCU.txt | 14 array that is separately indexed. It might be tempting to consider use 15 of RCU to instead protect the index into an array, however, this use 30 Hash tables are often implemented as an array, where each array entry 33 to other array-of-list situations, such as radix trees. 39 located in each array element, and where the array is never resized, 51 function formerly used by the System V IPC code. The array is used 60 the new array, and invokes ipc_rcu_putref() to free up the old array. 92 * contents of the new array are visible before the new 93 * array becomes visible. 101 The ipc_rcu_putref() function decrements the array's reference count [all …]
|
/Linux-v5.4/drivers/net/wireless/ath/ath9k/ |
D | calib.h | 36 #define STATIC_INI_ARRAY(array) { \ argument 37 .ia_array = (u32 *)(array), \ 38 .ia_rows = ARRAY_SIZE(array), \ 39 .ia_columns = ARRAY_SIZE(array[0]), \ 42 #define INIT_INI_ARRAY(iniarray, array) do { \ argument 43 (iniarray)->ia_array = (u32 *)(array); \ 44 (iniarray)->ia_rows = ARRAY_SIZE(array); \ 45 (iniarray)->ia_columns = ARRAY_SIZE(array[0]); \
|
/Linux-v5.4/kernel/trace/ |
D | tracing_map.h | 173 #define TRACING_MAP_ARRAY_ELT(array, idx) \ argument 174 (array->pages[idx >> array->entry_shift] + \ 175 ((idx & array->entry_mask) << array->entry_size_shift)) 177 #define TRACING_MAP_ENTRY(array, idx) \ argument 178 ((struct tracing_map_entry *)TRACING_MAP_ARRAY_ELT(array, idx)) 180 #define TRACING_MAP_ELT(array, idx) \ argument 181 ((struct tracing_map_elt **)TRACING_MAP_ARRAY_ELT(array, idx))
|
/Linux-v5.4/Documentation/admin-guide/ |
D | md.rst | 22 or, to assemble a partitionable array:: 44 level of the RAID array 92 If a raid5 or raid6 array is both dirty and degraded, it could have 98 For this reason, md will normally refuse to start such an array. This 99 requires the sysadmin to take action to explicitly start the array 104 This option is not really available if the array has the root 106 array, md supports a module parameter ``start_dirty_degraded`` which, 131 An array is ``created`` by writing appropriate superblocks to all 138 An array should be created by a user-space tool. This will write 139 superblocks to all devices. It will usually mark the array as [all …]
|
/Linux-v5.4/fs/dlm/ |
D | member.c | 62 struct rcom_slot *ro0, struct dlm_slot *array, in log_slots() argument 72 if (array) { in log_slots() 74 if (!array[i].nodeid) in log_slots() 78 array[i].slot, array[i].nodeid); in log_slots() 168 struct dlm_slot *array; in dlm_slots_assign() local 218 array = kcalloc(array_size, sizeof(*array), GFP_NOFS); in dlm_slots_assign() 219 if (!array) in dlm_slots_assign() 232 kfree(array); in dlm_slots_assign() 236 array[memb->slot - 1].nodeid = memb->nodeid; in dlm_slots_assign() 237 array[memb->slot - 1].slot = memb->slot; in dlm_slots_assign() [all …]
|
/Linux-v5.4/tools/perf/trace/beauty/ |
D | beauty.h | 16 #define DEFINE_STRARRAY(array, _prefix) struct strarray strarray__##array = { \ argument 17 .nr_entries = ARRAY_SIZE(array), \ 18 .entries = array, \ 22 #define DEFINE_STRARRAY_OFFSET(array, _prefix, off) struct strarray strarray__##array = { \ argument 24 .nr_entries = ARRAY_SIZE(array), \ 25 .entries = array, \ 47 #define DEFINE_STRARRAYS(array) struct strarrays strarrays__##array = { \ argument 48 .nr_entries = ARRAY_SIZE(array), \ 49 .entries = array, \
|
/Linux-v5.4/tools/virtio/ringtest/ |
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-v5.4/Documentation/core-api/ |
D | assoc_array.rst | 8 This associative array implementation is an object container with the following 18 2. Objects do not need to contain linkage blocks for use by the array. This 20 Rather, the array is made up of metadata blocks that point to objects. 22 3. Objects require index keys to locate them within the array. 25 already in the array will replace the old object. 32 7. Index keys can include a hash to scatter objects throughout the array. 34 8. The array can iterated over. The objects will not necessarily come out in 37 9. The array can be iterated over while it is being modified, provided the 43 10. Objects in the array can be looked up by means of their index key. 45 11. Objects can be looked up while the array is being modified, provided the [all …]
|
/Linux-v5.4/net/netfilter/ |
D | nf_conntrack_ftp.c | 122 static int try_number(const char *data, size_t dlen, u_int32_t array[], in try_number() argument 127 memset(array, 0, sizeof(array[0])*array_size); in try_number() 132 array[i] = array[i]*10 + *data - '0'; in try_number() 159 u_int32_t array[6]; in try_rfc959() local 161 length = try_number(data, dlen, array, 6, ',', term); in try_rfc959() 165 cmd->u3.ip = htonl((array[0] << 24) | (array[1] << 16) | in try_rfc959() 166 (array[2] << 8) | array[3]); in try_rfc959() 167 cmd->u.tcp.port = htons((array[4] << 8) | array[5]); in try_rfc959() 252 u_int32_t array[4]; in try_eprt() local 255 length = try_number(data + 3, dlen - 3, array, 4, '.', delim); in try_eprt() [all …]
|