Lines Matching refs:bpf_program
72 static bool prog_is_subprog(const struct bpf_object *obj, const struct bpf_program *prog);
373 struct bpf_program { struct
444 struct bpf_program **progs; argument
615 struct bpf_program *programs;
678 void bpf_program__unload(struct bpf_program *prog) in bpf_program__unload()
689 static void bpf_program__exit(struct bpf_program *prog) in bpf_program__exit()
726 bpf_object__init_prog(struct bpf_object *obj, struct bpf_program *prog, in bpf_object__init_prog()
790 struct bpf_program *prog, *progs; in bpf_object__add_programs()
1085 struct bpf_program *prog; in bpf_map__init_kern_struct_ops()
2946 static bool prog_needs_vmlinux_btf(struct bpf_program *prog) in prog_needs_vmlinux_btf()
2963 struct bpf_program *prog; in obj_needs_vmlinux_btf()
3039 struct bpf_program *prog = &obj->programs[i]; in bpf_object__sanitize_and_load_btf()
3292 const struct bpf_program *a = _a; in cmp_progs()
3293 const struct bpf_program *b = _b; in cmp_progs()
3887 static bool prog_is_subprog(const struct bpf_object *obj, const struct bpf_program *prog) in prog_is_subprog()
3892 struct bpf_program *
3896 struct bpf_program *prog; in bpf_object__find_program_by_name()
3944 static int bpf_program__record_reloc(struct bpf_program *prog, in bpf_program__record_reloc()
4097 static bool prog_contains_insn(const struct bpf_program *prog, size_t insn_idx) in prog_contains_insn()
4103 static struct bpf_program *find_prog_by_sec_insn(const struct bpf_object *obj, in find_prog_by_sec_insn()
4107 struct bpf_program *prog; in find_prog_by_sec_insn()
4133 struct bpf_program *prog; in bpf_object__collect_prog_relos()
5097 const struct bpf_program *targ_prog; in init_prog_array_slots()
5559 static int record_relo_core(struct bpf_program *prog, in record_relo_core()
5577 static const struct bpf_core_relo *find_relo_core(struct bpf_program *prog, int insn_idx) in find_relo_core()
5593 static int bpf_core_resolve_relo(struct bpf_program *prog, in bpf_core_resolve_relo()
5646 struct bpf_program *prog; in bpf_object__relocate_core()
5760 static void poison_map_ldimm64(struct bpf_program *prog, int relo_idx, in poison_map_ldimm64()
5792 bpf_object__relocate_data(struct bpf_object *obj, struct bpf_program *prog) in bpf_object__relocate_data()
5888 const struct bpf_program *prog, in adjust_prog_btf_ext_info()
5957 struct bpf_program *main_prog, in reloc_prog_func_and_line_info()
5958 const struct bpf_program *prog) in reloc_prog_func_and_line_info()
6037 static struct reloc_desc *find_prog_insn_relo(const struct bpf_program *prog, size_t insn_idx) in find_prog_insn_relo()
6045 static int append_subprog_relos(struct bpf_program *main_prog, struct bpf_program *subprog) in append_subprog_relos()
6071 bpf_object__reloc_code(struct bpf_object *obj, struct bpf_program *main_prog, in bpf_object__reloc_code()
6072 struct bpf_program *prog) in bpf_object__reloc_code()
6075 struct bpf_program *subprog; in bpf_object__reloc_code()
6278 bpf_object__relocate_calls(struct bpf_object *obj, struct bpf_program *prog) in bpf_object__relocate_calls()
6280 struct bpf_program *subprog; in bpf_object__relocate_calls()
6304 struct bpf_program *prog; in bpf_object__free_relocs()
6335 struct bpf_program *p = &obj->programs[i]; in bpf_object__sort_relos()
6347 struct bpf_program *prog; in bpf_object__relocate()
6433 struct bpf_program *targ_prog = NULL; in bpf_object__collect_map_relos()
6611 static int bpf_object__sanitize_prog(struct bpf_object *obj, struct bpf_program *prog) in bpf_object__sanitize_prog()
6646 static int libbpf_find_attach_btf_id(struct bpf_program *prog, const char *attach_name,
6650 static int libbpf_prepare_prog_load(struct bpf_program *prog, in libbpf_prepare_prog_load()
6705 static void fixup_verifier_log(struct bpf_program *prog, char *buf, size_t buf_sz);
6707 static int bpf_object_load_prog(struct bpf_object *obj, struct bpf_program *prog, in bpf_object_load_prog()
6924 static void fixup_log_failed_core_relo(struct bpf_program *prog, in fixup_log_failed_core_relo()
6963 static void fixup_log_missing_map_load(struct bpf_program *prog, in fixup_log_missing_map_load()
6996 static void fixup_verifier_log(struct bpf_program *prog, char *buf, size_t buf_sz) in fixup_verifier_log()
7036 static int bpf_program_record_relos(struct bpf_program *prog) in bpf_program_record_relos()
7079 struct bpf_program *prog; in bpf_object__load_progs()
7119 struct bpf_program *prog; in bpf_object_init_progs()
7776 int bpf_program__pin(struct bpf_program *prog, const char *path) in bpf_program__pin()
7805 int bpf_program__unpin(struct bpf_program *prog, const char *path) in bpf_program__unpin()
8041 struct bpf_program *prog; in bpf_object__pin_programs()
8078 struct bpf_program *prog; in bpf_object__unpin_programs()
8228 static struct bpf_program *
8229 __bpf_program__iter(const struct bpf_program *p, const struct bpf_object *obj, in __bpf_program__iter()
8254 struct bpf_program *
8255 bpf_object__next_program(const struct bpf_object *obj, struct bpf_program *prev) in bpf_object__next_program()
8257 struct bpf_program *prog = prev; in bpf_object__next_program()
8266 struct bpf_program *
8267 bpf_object__prev_program(const struct bpf_object *obj, struct bpf_program *next) in bpf_object__prev_program()
8269 struct bpf_program *prog = next; in bpf_object__prev_program()
8278 void bpf_program__set_ifindex(struct bpf_program *prog, __u32 ifindex) in bpf_program__set_ifindex()
8283 const char *bpf_program__name(const struct bpf_program *prog) in bpf_program__name()
8288 const char *bpf_program__section_name(const struct bpf_program *prog) in bpf_program__section_name()
8293 bool bpf_program__autoload(const struct bpf_program *prog) in bpf_program__autoload()
8298 int bpf_program__set_autoload(struct bpf_program *prog, bool autoload) in bpf_program__set_autoload()
8307 bool bpf_program__autoattach(const struct bpf_program *prog) in bpf_program__autoattach()
8312 void bpf_program__set_autoattach(struct bpf_program *prog, bool autoattach) in bpf_program__set_autoattach()
8317 const struct bpf_insn *bpf_program__insns(const struct bpf_program *prog) in bpf_program__insns()
8322 size_t bpf_program__insn_cnt(const struct bpf_program *prog) in bpf_program__insn_cnt()
8327 int bpf_program__set_insns(struct bpf_program *prog, in bpf_program__set_insns()
8347 int bpf_program__fd(const struct bpf_program *prog) in bpf_program__fd()
8359 enum bpf_prog_type bpf_program__get_type(const struct bpf_program *prog);
8361 enum bpf_prog_type bpf_program__type(const struct bpf_program *prog) in bpf_program__type()
8366 int bpf_program__set_type(struct bpf_program *prog, enum bpf_prog_type type) in bpf_program__set_type()
8376 enum bpf_attach_type bpf_program__get_expected_attach_type(const struct bpf_program *prog);
8378 enum bpf_attach_type bpf_program__expected_attach_type(const struct bpf_program *prog) in bpf_program__expected_attach_type()
8383 int bpf_program__set_expected_attach_type(struct bpf_program *prog, in bpf_program__set_expected_attach_type()
8393 __u32 bpf_program__flags(const struct bpf_program *prog) in bpf_program__flags()
8398 int bpf_program__set_flags(struct bpf_program *prog, __u32 flags) in bpf_program__set_flags()
8407 __u32 bpf_program__log_level(const struct bpf_program *prog) in bpf_program__log_level()
8412 int bpf_program__set_log_level(struct bpf_program *prog, __u32 log_level) in bpf_program__set_log_level()
8421 const char *bpf_program__log_buf(const struct bpf_program *prog, size_t *log_size) in bpf_program__log_buf()
8427 int bpf_program__set_log_buf(struct bpf_program *prog, char *log_buf, size_t log_size) in bpf_program__set_log_buf()
8450 static int attach_kprobe(const struct bpf_program *prog, long cookie, struct bpf_link **link);
8451 static int attach_uprobe(const struct bpf_program *prog, long cookie, struct bpf_link **link);
8452 static int attach_ksyscall(const struct bpf_program *prog, long cookie, struct bpf_link **link);
8453 static int attach_usdt(const struct bpf_program *prog, long cookie, struct bpf_link **link);
8454 static int attach_tp(const struct bpf_program *prog, long cookie, struct bpf_link **link);
8455 static int attach_raw_tp(const struct bpf_program *prog, long cookie, struct bpf_link **link);
8456 static int attach_trace(const struct bpf_program *prog, long cookie, struct bpf_link **link);
8457 static int attach_kprobe_multi(const struct bpf_program *prog, long cookie, struct bpf_link **link);
8458 static int attach_lsm(const struct bpf_program *prog, long cookie, struct bpf_link **link);
8459 static int attach_iter(const struct bpf_program *prog, long cookie, struct bpf_link **link);
8807 struct bpf_program *prog; in bpf_object__collect_st_ops_relos()
9068 static int libbpf_find_attach_btf_id(struct bpf_program *prog, const char *attach_name, in libbpf_find_attach_btf_id()
9511 int bpf_link__update_program(struct bpf_link *link, struct bpf_program *prog) in bpf_link__update_program()
9691 struct bpf_link *bpf_program__attach_perf_event_opts(const struct bpf_program *prog, int pfd, in bpf_program__attach_perf_event_opts()
9766 struct bpf_link *bpf_program__attach_perf_event(const struct bpf_program *prog, int pfd) in bpf_program__attach_perf_event()
10067 bpf_program__attach_kprobe_opts(const struct bpf_program *prog, in bpf_program__attach_kprobe_opts()
10140 struct bpf_link *bpf_program__attach_kprobe(const struct bpf_program *prog, in bpf_program__attach_kprobe()
10151 struct bpf_link *bpf_program__attach_ksyscall(const struct bpf_program *prog, in bpf_program__attach_ksyscall()
10233 bpf_program__attach_kprobe_multi_opts(const struct bpf_program *prog, in bpf_program__attach_kprobe_multi_opts()
10312 static int attach_kprobe(const struct bpf_program *prog, long cookie, struct bpf_link **link) in attach_kprobe()
10349 static int attach_ksyscall(const struct bpf_program *prog, long cookie, struct bpf_link **link) in attach_ksyscall()
10370 static int attach_kprobe_multi(const struct bpf_program *prog, long cookie, struct bpf_link **link) in attach_kprobe_multi()
10734 bpf_program__attach_uprobe_opts(const struct bpf_program *prog, pid_t pid, in bpf_program__attach_uprobe_opts()
10843 static int attach_uprobe(const struct bpf_program *prog, long cookie, struct bpf_link **link) in attach_uprobe()
10888 struct bpf_link *bpf_program__attach_uprobe(const struct bpf_program *prog, in bpf_program__attach_uprobe()
10898 struct bpf_link *bpf_program__attach_usdt(const struct bpf_program *prog, in bpf_program__attach_usdt()
10951 static int attach_usdt(const struct bpf_program *prog, long cookie, struct bpf_link **link) in attach_usdt()
11031 struct bpf_link *bpf_program__attach_tracepoint_opts(const struct bpf_program *prog, in bpf_program__attach_tracepoint_opts()
11065 struct bpf_link *bpf_program__attach_tracepoint(const struct bpf_program *prog, in bpf_program__attach_tracepoint()
11072 static int attach_tp(const struct bpf_program *prog, long cookie, struct bpf_link **link) in attach_tp()
11104 struct bpf_link *bpf_program__attach_raw_tracepoint(const struct bpf_program *prog, in bpf_program__attach_raw_tracepoint()
11134 static int attach_raw_tp(const struct bpf_program *prog, long cookie, struct bpf_link **link) in attach_raw_tp()
11176 static struct bpf_link *bpf_program__attach_btf_id(const struct bpf_program *prog, in bpf_program__attach_btf_id()
11212 struct bpf_link *bpf_program__attach_trace(const struct bpf_program *prog) in bpf_program__attach_trace()
11217 struct bpf_link *bpf_program__attach_trace_opts(const struct bpf_program *prog, in bpf_program__attach_trace_opts()
11223 struct bpf_link *bpf_program__attach_lsm(const struct bpf_program *prog) in bpf_program__attach_lsm()
11228 static int attach_trace(const struct bpf_program *prog, long cookie, struct bpf_link **link) in attach_trace()
11234 static int attach_lsm(const struct bpf_program *prog, long cookie, struct bpf_link **link) in attach_lsm()
11241 bpf_program__attach_fd(const struct bpf_program *prog, int target_fd, int btf_id, in bpf_program__attach_fd()
11277 bpf_program__attach_cgroup(const struct bpf_program *prog, int cgroup_fd) in bpf_program__attach_cgroup()
11283 bpf_program__attach_netns(const struct bpf_program *prog, int netns_fd) in bpf_program__attach_netns()
11288 struct bpf_link *bpf_program__attach_xdp(const struct bpf_program *prog, int ifindex) in bpf_program__attach_xdp()
11294 struct bpf_link *bpf_program__attach_freplace(const struct bpf_program *prog, in bpf_program__attach_freplace()
11327 bpf_program__attach_iter(const struct bpf_program *prog, in bpf_program__attach_iter()
11366 static int attach_iter(const struct bpf_program *prog, long cookie, struct bpf_link **link) in attach_iter()
11372 struct bpf_link *bpf_program__attach(const struct bpf_program *prog) in bpf_program__attach()
11421 struct bpf_program *prog = st_ops->progs[i]; in bpf_map__attach_struct_ops()
11999 int bpf_program__set_attach_target(struct bpf_program *prog, in bpf_program__set_attach_target()
12179 struct bpf_program **prog = progs[i].prog; in populate_skeleton_progs()
12364 struct bpf_program *prog = *s->progs[i].prog; in bpf_object__attach_skeleton()