/kernel/bpf/ |
D | arraymap.c | 81 static struct bpf_map *array_map_alloc(union bpf_attr *attr) in array_map_alloc() 175 static void *array_map_lookup_elem(struct bpf_map *map, void *key) in array_map_lookup_elem() 186 static int array_map_direct_value_addr(const struct bpf_map *map, u64 *imm, in array_map_direct_value_addr() 200 static int array_map_direct_value_meta(const struct bpf_map *map, u64 imm, in array_map_direct_value_meta() 217 static int array_map_gen_lookup(struct bpf_map *map, struct bpf_insn *insn_buf) in array_map_gen_lookup() 250 static void *percpu_array_map_lookup_elem(struct bpf_map *map, void *key) in percpu_array_map_lookup_elem() 261 int bpf_percpu_array_copy(struct bpf_map *map, void *key, void *value) in bpf_percpu_array_copy() 288 static int array_map_get_next_key(struct bpf_map *map, void *key, void *next_key) in array_map_get_next_key() 307 static int array_map_update_elem(struct bpf_map *map, void *key, void *value, in array_map_update_elem() 344 int bpf_percpu_array_update(struct bpf_map *map, void *key, void *value, in bpf_percpu_array_update() [all …]
|
D | queue_stack_maps.c | 17 struct bpf_map map; 25 static struct bpf_queue_stack *bpf_queue_stack(struct bpf_map *map) in bpf_queue_stack() 67 static struct bpf_map *queue_stack_map_alloc(union bpf_attr *attr) in queue_stack_map_alloc() 100 static void queue_stack_map_free(struct bpf_map *map) in queue_stack_map_free() 107 static int __queue_map_get(struct bpf_map *map, void *value, bool delete) in __queue_map_get() 141 static int __stack_map_get(struct bpf_map *map, void *value, bool delete) in __stack_map_get() 178 static int queue_map_peek_elem(struct bpf_map *map, void *value) in queue_map_peek_elem() 184 static int stack_map_peek_elem(struct bpf_map *map, void *value) in stack_map_peek_elem() 190 static int queue_map_pop_elem(struct bpf_map *map, void *value) in queue_map_pop_elem() 196 static int stack_map_pop_elem(struct bpf_map *map, void *value) in stack_map_pop_elem() [all …]
|
D | map_in_map.c | 9 struct bpf_map *bpf_map_meta_alloc(int inner_map_ufd) in bpf_map_meta_alloc() 11 struct bpf_map *inner_map, *inner_map_meta; in bpf_map_meta_alloc() 66 void bpf_map_meta_free(struct bpf_map *map_meta) in bpf_map_meta_free() 71 bool bpf_map_meta_equal(const struct bpf_map *meta0, in bpf_map_meta_equal() 72 const struct bpf_map *meta1) in bpf_map_meta_equal() 81 void *bpf_map_fd_get_ptr(struct bpf_map *map, in bpf_map_fd_get_ptr() 85 struct bpf_map *inner_map, *inner_map_meta; in bpf_map_fd_get_ptr() 113 return ((struct bpf_map *)ptr)->id; in bpf_map_fd_sys_lookup_elem()
|
D | bpf_inode_storage.c | 36 struct bpf_map *map, in inode_storage_lookup() 103 static void *bpf_fd_inode_storage_lookup_elem(struct bpf_map *map, void *key) in bpf_fd_inode_storage_lookup_elem() 119 static int bpf_fd_inode_storage_update_elem(struct bpf_map *map, void *key, in bpf_fd_inode_storage_update_elem() 142 static int inode_storage_delete(struct inode *inode, struct bpf_map *map) in inode_storage_delete() 155 static int bpf_fd_inode_storage_delete_elem(struct bpf_map *map, void *key) in bpf_fd_inode_storage_delete_elem() 170 BPF_CALL_4(bpf_inode_storage_get, struct bpf_map *, map, struct inode *, inode, in BPF_CALL_4() argument 205 struct bpf_map *, map, struct inode *, inode) in BPF_CALL_2() argument 216 static int notsupp_get_next_key(struct bpf_map *map, void *key, in notsupp_get_next_key() 222 static struct bpf_map *inode_storage_map_alloc(union bpf_attr *attr) in inode_storage_map_alloc() 234 static void inode_storage_map_free(struct bpf_map *map) in inode_storage_map_free()
|
D | map_iter.c | 16 struct bpf_map *map; in bpf_map_seq_start() 33 bpf_map_put((struct bpf_map *)v); in bpf_map_seq_next() 39 __bpf_md_ptr(struct bpf_map *, map); 42 DEFINE_BPF_ITER_FUNC(bpf_map, struct bpf_iter_meta *meta, struct bpf_map *map) in DEFINE_BPF_ITER_FUNC() argument 71 bpf_map_put((struct bpf_map *)v); in bpf_map_seq_stop() 82 BTF_ID(struct, bpf_map) 106 struct bpf_map *map; in bpf_iter_attach_map() 166 struct bpf_map *map, void *key, void *value)
|
D | hashtab.c | 90 struct bpf_map map; 195 static void *fd_htab_map_get_ptr(const struct bpf_map *map, struct htab_elem *l) in fd_htab_map_get_ptr() 411 static struct bpf_map *htab_map_alloc(union bpf_attr *attr) in htab_map_alloc() 574 static void *__htab_map_lookup_elem(struct bpf_map *map, void *key) in __htab_map_lookup_elem() 594 static void *htab_map_lookup_elem(struct bpf_map *map, void *key) in htab_map_lookup_elem() 615 static int htab_map_gen_lookup(struct bpf_map *map, struct bpf_insn *insn_buf) in htab_map_gen_lookup() 621 (void *(*)(struct bpf_map *map, void *key))NULL)); in htab_map_gen_lookup() 630 static __always_inline void *__htab_lru_map_lookup_elem(struct bpf_map *map, in __htab_lru_map_lookup_elem() 644 static void *htab_lru_map_lookup_elem(struct bpf_map *map, void *key) in htab_lru_map_lookup_elem() 649 static void *htab_lru_map_lookup_elem_sys(struct bpf_map *map, void *key) in htab_lru_map_lookup_elem_sys() [all …]
|
D | local_storage.c | 23 struct bpf_map map; 30 static struct bpf_cgroup_storage_map *map_to_storage(struct bpf_map *map) in map_to_storage() 35 static bool attach_type_isolated(const struct bpf_map *map) in attach_type_isolated() 133 static void *cgroup_storage_lookup_elem(struct bpf_map *_map, void *key) in cgroup_storage_lookup_elem() 145 static int cgroup_storage_update_elem(struct bpf_map *map, void *key, in cgroup_storage_update_elem() 184 int bpf_percpu_cgroup_storage_copy(struct bpf_map *_map, void *key, in bpf_percpu_cgroup_storage_copy() 213 int bpf_percpu_cgroup_storage_update(struct bpf_map *_map, void *key, in bpf_percpu_cgroup_storage_update() 247 static int cgroup_storage_get_next_key(struct bpf_map *_map, void *key, in cgroup_storage_get_next_key() 287 static struct bpf_map *cgroup_storage_map_alloc(union bpf_attr *attr) in cgroup_storage_map_alloc() 335 static void cgroup_storage_map_free(struct bpf_map *_map) in cgroup_storage_map_free() [all …]
|
D | ringbuf.c | 51 struct bpf_map map; 152 static struct bpf_map *ringbuf_map_alloc(union bpf_attr *attr) in ringbuf_map_alloc() 214 static void ringbuf_map_free(struct bpf_map *map) in ringbuf_map_free() 223 static void *ringbuf_map_lookup_elem(struct bpf_map *map, void *key) in ringbuf_map_lookup_elem() 228 static int ringbuf_map_update_elem(struct bpf_map *map, void *key, void *value, in ringbuf_map_update_elem() 234 static int ringbuf_map_delete_elem(struct bpf_map *map, void *key) in ringbuf_map_delete_elem() 239 static int ringbuf_map_get_next_key(struct bpf_map *map, void *key, in ringbuf_map_get_next_key() 245 static int ringbuf_map_mmap(struct bpf_map *map, struct vm_area_struct *vma) in ringbuf_map_mmap() 272 static __poll_t ringbuf_map_poll(struct bpf_map *map, struct file *filp, in ringbuf_map_poll() 370 BPF_CALL_3(bpf_ringbuf_reserve, struct bpf_map *, map, u64, size, u64, flags) in BPF_CALL_3() argument [all …]
|
D | map_in_map.h | 10 struct bpf_map; 12 struct bpf_map *bpf_map_meta_alloc(int inner_map_ufd); 13 void bpf_map_meta_free(struct bpf_map *map_meta); 14 void *bpf_map_fd_get_ptr(struct bpf_map *map, struct file *map_file,
|
D | reuseport_array.c | 11 struct bpf_map map; 15 static struct reuseport_array *reuseport_array(struct bpf_map *map) in reuseport_array() 52 static void *reuseport_array_lookup_elem(struct bpf_map *map, void *key) in reuseport_array_lookup_elem() 64 static int reuseport_array_delete_elem(struct bpf_map *map, void *key) in reuseport_array_delete_elem() 96 static void reuseport_array_free(struct bpf_map *map) in reuseport_array_free() 151 static struct bpf_map *reuseport_array_alloc(union bpf_attr *attr) in reuseport_array_alloc() 182 int bpf_fd_reuseport_array_lookup_elem(struct bpf_map *map, void *key, in bpf_fd_reuseport_array_lookup_elem() 249 int bpf_fd_reuseport_array_update_elem(struct bpf_map *map, void *key, in bpf_fd_reuseport_array_update_elem() 333 static int reuseport_array_get_next_key(struct bpf_map *map, void *key, in reuseport_array_get_next_key()
|
D | devmap.c | 74 struct bpf_map map; 170 static struct bpf_map *dev_map_alloc(union bpf_attr *attr) in dev_map_alloc() 195 static void dev_map_free(struct bpf_map *map) in dev_map_free() 258 static int dev_map_get_next_key(struct bpf_map *map, void *key, void *next_key) in dev_map_get_next_key() 275 struct bpf_dtab_netdev *__dev_map_hash_lookup_elem(struct bpf_map *map, u32 key) in __dev_map_hash_lookup_elem() 289 static int dev_map_hash_get_next_key(struct bpf_map *map, void *key, in dev_map_hash_get_next_key() 334 bool dev_map_can_have_prog(struct bpf_map *map) in dev_map_can_have_prog() 409 struct bpf_dtab_netdev *__dev_map_lookup_elem(struct bpf_map *map, u32 key) in __dev_map_lookup_elem() 528 static void *dev_map_lookup_elem(struct bpf_map *map, void *key) in dev_map_lookup_elem() 535 static void *dev_map_hash_lookup_elem(struct bpf_map *map, void *key) in dev_map_hash_lookup_elem() [all …]
|
D | syscall.c | 104 static struct bpf_map *find_and_alloc_map(union bpf_attr *attr) in find_and_alloc_map() 108 struct bpf_map *map; in find_and_alloc_map() 133 static void bpf_map_write_active_inc(struct bpf_map *map) in bpf_map_write_active_inc() 138 static void bpf_map_write_active_dec(struct bpf_map *map) in bpf_map_write_active_dec() 143 bool bpf_map_write_active(const struct bpf_map *map) in bpf_map_write_active() 148 static u32 bpf_map_value_size(struct bpf_map *map) in bpf_map_value_size() 161 static void maybe_wait_bpf_programs(struct bpf_map *map) in maybe_wait_bpf_programs() 172 static int bpf_map_update_value(struct bpf_map *map, struct fd f, void *key, in bpf_map_update_value() 228 static int bpf_map_copy_value(struct bpf_map *map, void *key, void *value, in bpf_map_copy_value() 352 void bpf_map_init_from_attr(struct bpf_map *map, union bpf_attr *attr) in bpf_map_init_from_attr() [all …]
|
D | bpf_struct_ops.c | 31 struct bpf_map map; 232 static int bpf_struct_ops_map_get_next_key(struct bpf_map *map, void *key, in bpf_struct_ops_map_get_next_key() 242 int bpf_struct_ops_map_sys_lookup_elem(struct bpf_map *map, void *key, in bpf_struct_ops_map_sys_lookup_elem() 271 static void *bpf_struct_ops_map_lookup_elem(struct bpf_map *map, void *key) in bpf_struct_ops_map_lookup_elem() 315 static int bpf_struct_ops_map_update_elem(struct bpf_map *map, void *key, in bpf_struct_ops_map_update_elem() 488 static int bpf_struct_ops_map_delete_elem(struct bpf_map *map, void *key) in bpf_struct_ops_map_delete_elem() 514 static void bpf_struct_ops_map_seq_show_elem(struct bpf_map *map, void *key, in bpf_struct_ops_map_seq_show_elem() 534 static void bpf_struct_ops_map_free(struct bpf_map *map) in bpf_struct_ops_map_free() 556 static struct bpf_map *bpf_struct_ops_map_alloc(union bpf_attr *attr) in bpf_struct_ops_map_alloc() 563 struct bpf_map *map; in bpf_struct_ops_map_alloc()
|
D | stackmap.c | 28 struct bpf_map map; 54 static inline bool stack_map_use_build_id(struct bpf_map *map) in stack_map_use_build_id() 59 static inline int stack_map_data_size(struct bpf_map *map) in stack_map_data_size() 90 static struct bpf_map *stack_map_alloc(union bpf_attr *attr) in stack_map_alloc() 397 static long __bpf_get_stackid(struct bpf_map *map, in __bpf_get_stackid() 467 BPF_CALL_3(bpf_get_stackid, struct pt_regs *, regs, struct bpf_map *, map, in BPF_CALL_3() argument 516 struct bpf_map *, map, u64, flags) in BPF_CALL_3() argument 758 static void *stack_map_lookup_elem(struct bpf_map *map, void *key) in stack_map_lookup_elem() 764 int bpf_stackmap_copy(struct bpf_map *map, void *key, void *value) in bpf_stackmap_copy() 787 static int stack_map_get_next_key(struct bpf_map *map, void *key, in stack_map_get_next_key() [all …]
|
D | helpers.c | 30 BPF_CALL_2(bpf_map_lookup_elem, struct bpf_map *, map, void *, key) in BPF_CALL_2() argument 45 BPF_CALL_4(bpf_map_update_elem, struct bpf_map *, map, void *, key, in BPF_CALL_4() argument 63 BPF_CALL_2(bpf_map_delete_elem, struct bpf_map *, map, void *, key) in BPF_CALL_2() argument 78 BPF_CALL_3(bpf_map_push_elem, struct bpf_map *, map, void *, value, u64, flags) in BPF_CALL_3() argument 93 BPF_CALL_2(bpf_map_pop_elem, struct bpf_map *, map, void *, value) in BPF_CALL_2() argument 106 BPF_CALL_2(bpf_map_peek_elem, struct bpf_map *, map, void *, value) in BPF_CALL_2() argument 315 void copy_map_value_locked(struct bpf_map *map, void *dst, void *src, in copy_map_value_locked() 378 BPF_CALL_2(bpf_get_local_storage, struct bpf_map *, map, u64, flags) in BPF_CALL_2() argument 592 BPF_CALL_5(bpf_event_output_data, void *, ctx, struct bpf_map *, map, in BPF_CALL_5() argument
|
D | cpumap.c | 75 struct bpf_map map; 82 static struct bpf_map *cpu_map_alloc(union bpf_attr *attr) in cpu_map_alloc() 389 bool cpu_map_prog_allowed(struct bpf_map *map) in cpu_map_prog_allowed() 533 static int cpu_map_delete_elem(struct bpf_map *map, void *key) in cpu_map_delete_elem() 546 static int cpu_map_update_elem(struct bpf_map *map, void *key, void *value, in cpu_map_update_elem() 585 static void cpu_map_free(struct bpf_map *map) in cpu_map_free() 619 struct bpf_cpu_map_entry *__cpu_map_lookup_elem(struct bpf_map *map, u32 key) in __cpu_map_lookup_elem() 631 static void *cpu_map_lookup_elem(struct bpf_map *map, void *key) in cpu_map_lookup_elem() 639 static int cpu_map_get_next_key(struct bpf_map *map, void *key, void *next_key) in cpu_map_get_next_key()
|
D | lpm_trie.c | 32 struct bpf_map map; 227 static void *trie_lookup_elem(struct bpf_map *map, void *_key) in trie_lookup_elem() 303 static int trie_update_elem(struct bpf_map *map, in trie_update_elem() 434 static int trie_delete_elem(struct bpf_map *map, void *_key) in trie_delete_elem() 543 static struct bpf_map *trie_alloc(union bpf_attr *attr) in trie_alloc() 589 static void trie_free(struct bpf_map *map) in trie_free() 628 static int trie_get_next_key(struct bpf_map *map, void *_key, void *_next_key) in trie_get_next_key() 726 static int trie_check_btf(const struct bpf_map *map, in trie_check_btf()
|
D | offload.c | 362 struct bpf_map *bpf_map_offload_map_alloc(union bpf_attr *attr) in bpf_map_offload_map_alloc() 420 void bpf_map_offload_map_free(struct bpf_map *map) in bpf_map_offload_map_free() 434 int bpf_map_offload_lookup_elem(struct bpf_map *map, void *key, void *value) in bpf_map_offload_lookup_elem() 447 int bpf_map_offload_update_elem(struct bpf_map *map, in bpf_map_offload_update_elem() 465 int bpf_map_offload_delete_elem(struct bpf_map *map, void *key) in bpf_map_offload_delete_elem() 478 int bpf_map_offload_get_next_key(struct bpf_map *map, void *key, void *next_key) in bpf_map_offload_get_next_key() 521 int bpf_map_offload_info_fill(struct bpf_map_info *info, struct bpf_map *map) in bpf_map_offload_info_fill() 579 bool bpf_offload_prog_map_match(struct bpf_prog *prog, struct bpf_map *map) in bpf_offload_prog_map_match()
|
D | inode.c | 183 static struct bpf_map *seq_file_to_map(struct seq_file *m) in seq_file_to_map() 196 static struct map_iter *map_iter_alloc(struct bpf_map *map) in map_iter_alloc() 217 struct bpf_map *map = seq_file_to_map(m); in map_seq_next() 253 struct bpf_map *map = seq_file_to_map(m); in map_seq_show() 275 struct bpf_map *map = inode->i_private; in bpffs_map_open() 355 struct bpf_map *map = arg; in bpf_mkmap()
|
D | bpf_local_storage.c | 26 struct bpf_map *map = &smap->map; in mem_charge() 37 struct bpf_map *map = &smap->map; in mem_uncharge() 46 struct bpf_map *map = &smap->map; in owner_storage() 595 int bpf_local_storage_map_check_btf(const struct bpf_map *map, in bpf_local_storage_map_check_btf()
|
D | verifier.c | 187 #define BPF_MAP_PTR(X) ((struct bpf_map *)((X) & ~BPF_MAP_PTR_UNPRIV)) 200 const struct bpf_map *map, bool unpriv) in bpf_map_ptr_store() 232 struct bpf_map *map_ptr; 470 const struct bpf_map *map) in is_acquire_function() 3002 struct bpf_map *map = regs[regno].map_ptr; in check_map_access_type() 3118 struct bpf_map *map = reg->map_ptr; in check_map_access() 3725 static bool bpf_map_is_rdonly(const struct bpf_map *map) in bpf_map_is_rdonly() 3745 static int bpf_map_direct_read(struct bpf_map *map, int off, int size, u64 *val) in bpf_map_direct_read() 3832 struct bpf_map *map = reg->map_ptr; in check_ptr_to_map_access() 3998 struct bpf_map *map = reg->map_ptr; in check_mem_access() [all …]
|
D | core.c | 1574 struct bpf_map *map = (struct bpf_map *) (unsigned long) BPF_R2; in ___bpf_prog_run() 1814 struct bpf_map *map = aux->used_maps[i]; in bpf_check_tail_call() 2166 struct bpf_map **used_maps, u32 len) in __bpf_free_used_maps() 2168 struct bpf_map *map; in __bpf_free_used_maps() 2286 bpf_event_output(struct bpf_map *map, u64 flags, void *meta, u64 meta_size, in bpf_event_output()
|
/kernel/bpf/preload/iterators/ |
D | iterators.bpf.c | 16 struct bpf_map { struct 24 struct bpf_map *map; argument 82 struct bpf_map *map = ctx->map; in dump_bpf_map()
|
D | iterators.skel.h | 14 struct bpf_map *rodata;
|
/kernel/trace/ |
D | bpf_trace.c | 804 get_map_perf_counter(struct bpf_map *map, u64 flags, in get_map_perf_counter() 826 BPF_CALL_2(bpf_perf_event_read, struct bpf_map *, map, u64, flags) in BPF_CALL_2() argument 849 BPF_CALL_4(bpf_perf_event_read_value, struct bpf_map *, map, u64, flags, in BPF_CALL_4() argument 877 __bpf_perf_event_output(struct pt_regs *regs, struct bpf_map *map, in __bpf_perf_event_output() 916 BPF_CALL_5(bpf_perf_event_output, struct pt_regs *, regs, struct bpf_map *, map, in BPF_CALL_5() argument 970 u64 bpf_event_output(struct bpf_map *map, u64 flags, void *meta, u64 meta_size, in bpf_event_output() 1024 BPF_CALL_2(bpf_current_task_under_cgroup, struct bpf_map *, map, u32, idx) in BPF_CALL_2() argument 1405 BPF_CALL_5(bpf_perf_event_output_tp, void *, tp_buff, struct bpf_map *, map, in BPF_CALL_5() argument 1429 BPF_CALL_3(bpf_get_stackid_tp, void *, tp_buff, struct bpf_map *, map, in BPF_CALL_3() argument 1621 struct bpf_map *, map, u64, flags, void *, data, u64, size) in BPF_CALL_5() argument [all …]
|