Home
last modified time | relevance | path

Searched refs:elem_sz (Results 1 – 2 of 2) sorted by relevance

/tools/lib/bpf/
Dlibbpf_internal.h195 void *libbpf_add_mem(void **data, size_t *cap_cnt, size_t elem_sz,
197 int libbpf_ensure_mem(void **data, size_t *cap_cnt, size_t elem_sz, size_t need_cnt);
Dbtf.c141 void *libbpf_add_mem(void **data, size_t *cap_cnt, size_t elem_sz, in libbpf_add_mem() argument
148 return *data + cur_cnt * elem_sz; in libbpf_add_mem()
163 new_data = libbpf_reallocarray(*data, new_cnt, elem_sz); in libbpf_add_mem()
168 memset(new_data + (*cap_cnt) * elem_sz, 0, (new_cnt - *cap_cnt) * elem_sz); in libbpf_add_mem()
172 return new_data + cur_cnt * elem_sz; in libbpf_add_mem()
178 int libbpf_ensure_mem(void **data, size_t *cap_cnt, size_t elem_sz, size_t need_cnt) in libbpf_ensure_mem() argument
185 p = libbpf_add_mem(data, cap_cnt, elem_sz, *cap_cnt, SIZE_MAX, need_cnt - *cap_cnt); in libbpf_ensure_mem()