/linux/tools/include/linux/ |
H A D | filter.h | 35 ((struct bpf_insn) { \ 43 ((struct bpf_insn) { \ 53 ((struct bpf_insn) { \ 61 ((struct bpf_insn) { \ 71 ((struct bpf_insn) { \ 81 ((struct bpf_insn) { \ 89 ((struct bpf_insn) { \ 99 ((struct bpf_insn) { \ 107 ((struct bpf_insn) { \ 117 ((struct bpf_insn) { \ [all …]
|
/linux/samples/bpf/ |
H A D | bpf_insn.h | 6 struct bpf_insn; 11 ((struct bpf_insn) { \ 19 ((struct bpf_insn) { \ 29 ((struct bpf_insn) { \ 37 ((struct bpf_insn) { \ 47 ((struct bpf_insn) { \ 55 ((struct bpf_insn) { \ 65 ((struct bpf_insn) { \ 73 ((struct bpf_insn) { \ 85 ((struct bpf_insn) { \ [all …]
|
H A D | test_cgrp2_sock.c | 33 struct bpf_insn prog_start[] = { in prog_load() 36 struct bpf_insn prog_end[] = { in prog_load() 42 struct bpf_insn prog_dev[] = { in prog_load() 49 struct bpf_insn prog_mark[] = { in prog_load() 67 struct bpf_insn prog_prio[] = { in prog_load() 78 struct bpf_insn *prog; in prog_load() 120 insns_cnt /= sizeof(struct bpf_insn); in prog_load()
|
/linux/tools/lib/bpf/ |
H A D | gen_loader.c | 96 static void emit(struct bpf_gen *gen, struct bpf_insn insn) in emit() 104 static void emit2(struct bpf_gen *gen, struct bpf_insn insn1, struct bpf_insn insn2) in emit2() 674 move_blob2blob(gen, insn + offsetof(struct bpf_insn, imm), 4, in emit_relo_kfunc_btf() 675 kdesc->insn + offsetof(struct bpf_insn, imm)); in emit_relo_kfunc_btf() 676 move_blob2blob(gen, insn + offsetof(struct bpf_insn, off), 2, in emit_relo_kfunc_btf() 677 kdesc->insn + offsetof(struct bpf_insn, off)); in emit_relo_kfunc_btf() 697 emit(gen, BPF_ST_MEM(BPF_W, BPF_REG_8, offsetof(struct bpf_insn, imm), 0)); in emit_relo_kfunc_btf() 698 emit(gen, BPF_ST_MEM(BPF_H, BPF_REG_8, offsetof(struct bpf_insn, off), 0)); in emit_relo_kfunc_btf() 702 emit(gen, BPF_STX_MEM(BPF_W, BPF_REG_8, BPF_REG_7, offsetof(struct bpf_insn, imm))); in emit_relo_kfunc_btf() 714 emit(gen, BPF_ST_MEM(BPF_H, BPF_REG_8, offsetof(struct bpf_insn, off), 0)); in emit_relo_kfunc_btf() [all …]
|
H A D | features.c | 26 struct bpf_insn insns[] = { in probe_kern_prog_name() 51 struct bpf_insn insns[] = { in probe_kern_global_data() 233 struct bpf_insn insns[] = { in probe_kern_exp_attach_type() 254 struct bpf_insn insns[] = { in probe_kern_probe_read_kernel() 271 struct bpf_insn insns[] = { in probe_prog_bind_map() 339 struct bpf_insn insns[] = { in probe_perf_link() 375 struct bpf_insn insns[] = { in probe_uprobe_multi_link() 434 struct bpf_insn insns[] = { in probe_kern_arg_ctx_tag() 480 const struct bpf_insn insns[] = { in probe_kern_arg_ctx_tag()
|
/linux/include/linux/ |
H A D | filter.h | 103 ((struct bpf_insn) { \ 114 ((struct bpf_insn) { \ 127 ((struct bpf_insn) { \ 137 ((struct bpf_insn) { \ 149 ((struct bpf_insn) { \ 159 ((struct bpf_insn) { \ 169 ((struct bpf_insn) { \ 177 ((struct bpf_insn) { \ 191 ((struct bpf_insn) { \ 198 static inline bool insn_is_mov_percpu_addr(const struct bpf_insn *insn) in insn_is_mov_percpu_addr() [all …]
|
H A D | bpf.h | 72 const struct bpf_insn *); 120 int (*map_gen_lookup)(struct bpf_map *map, struct bpf_insn *insn_buf); 958 static bool bpf_is_ldimm64(const struct bpf_insn *insn) in bpf_is_ldimm64() 963 static inline bool bpf_pseudo_func(const struct bpf_insn *insn) in bpf_pseudo_func() 986 int (*gen_prologue)(struct bpf_insn *insn, bool direct_write, 988 int (*gen_epilogue)(struct bpf_insn *insn, const struct bpf_prog *prog, 990 int (*gen_ld_abs)(const struct bpf_insn *orig, 991 struct bpf_insn *insn_buf); 993 const struct bpf_insn *src, 994 struct bpf_insn *dst, [all …]
|
/linux/tools/testing/selftests/bpf/ |
H A D | test_verifier.c | 90 struct bpf_insn insns[MAX_INSNS]; 91 struct bpf_insn *fill_insns; 103 struct bpf_insn expected_insns[MAX_EXPECTED_INSNS]; 108 struct bpf_insn unexpected_insns[MAX_UNEXPECTED_INSNS]; 196 struct bpf_insn *insn = self->fill_insns; in bpf_fill_ld_abs_vlan_push_pop() 239 struct bpf_insn *insn = self->fill_insns; in bpf_fill_jump_around_ld_abs() 261 struct bpf_insn *insn = self->fill_insns; in bpf_fill_rand_ld_dw() 268 struct bpf_insn tmp[2] = { BPF_LD_IMM64(BPF_REG_1, val) }; in bpf_fill_rand_ld_dw() 289 struct bpf_insn *insn = self->fill_insns; in bpf_fill_scale1() 315 struct bpf_insn *insn = self->fill_insns; in bpf_fill_scale2() [all …]
|
H A D | disasm_helpers.h | 8 struct bpf_insn; 10 struct bpf_insn *disasm_insn(struct bpf_insn *insn, char *buf, size_t buf_sz);
|
H A D | disasm.h | 25 const struct bpf_insn *insn); 27 const struct bpf_insn *insn, 38 const struct bpf_insn *insn,
|
H A D | testing_helpers.h | 19 int bpf_test_load_program(enum bpf_prog_type type, const struct bpf_insn *insns, 53 struct bpf_insn; 57 int get_xlated_program(int fd_prog, struct bpf_insn **buf, __u32 *cnt);
|
H A D | disasm_helpers.c | 22 static const char *print_call_cb(void *private_data, const struct bpf_insn *insn) in print_call_cb() 38 struct bpf_insn *disasm_insn(struct bpf_insn *insn, char *buf, size_t buf_sz) in disasm_insn()
|
H A D | disasm.c | 17 const struct bpf_insn *insn, in __func_get_name() 44 const struct bpf_insn *insn, in __func_imm_name() 140 const struct bpf_insn *insn) in print_bpf_end_insn() 150 const struct bpf_insn *insn) in print_bpf_bswap_insn() 157 static bool is_sdiv_smod(const struct bpf_insn *insn) in is_sdiv_smod() 163 static bool is_movsx(const struct bpf_insn *insn) in is_movsx() 169 static bool is_addr_space_cast(const struct bpf_insn *insn) in is_addr_space_cast() 181 static inline bool is_mov_percpu_addr(const struct bpf_insn *insn) in is_mov_percpu_addr() 187 const struct bpf_insn *insn, in print_bpf_insn()
|
H A D | test_tag.c | 25 static struct bpf_insn prog[BPF_MAXINSNS]; 42 struct bpf_insn tmp[] = { in bpf_gen_map_prog() 133 insns *= sizeof(struct bpf_insn); in tag_from_alg()
|
/linux/tools/bpf/bpftool/ |
H A D | cfg.c | 20 struct bpf_insn *start; 21 struct bpf_insn *end; 30 struct bpf_insn *head; 31 struct bpf_insn *tail; 63 static struct func_node *cfg_append_func(struct cfg *cfg, struct bpf_insn *insn) in cfg_append_func() 89 struct bpf_insn *insn) in func_append_bb() 131 static bool cfg_partition_funcs(struct cfg *cfg, struct bpf_insn *cur, in cfg_partition_funcs() 132 struct bpf_insn *end) in cfg_partition_funcs() 167 struct bpf_insn *cur, *end; in func_partition_bb_head() 244 struct bpf_insn *insn) in func_search_bb_with_head() [all …]
|
H A D | xlated_dumper.c | 148 const struct bpf_insn *insn) in print_call_pcrel() 177 const struct bpf_insn *insn) in print_call() 195 const struct bpf_insn *insn, in print_imm() 229 struct bpf_insn *insn = buf; in dump_xlated_json() 314 struct bpf_insn *insn = buf; in dump_xlated_plain() 380 struct bpf_insn *insn_start = buf_start; in dump_xlated_for_graph() 381 struct bpf_insn *insn_end = buf_end; in dump_xlated_for_graph() 382 struct bpf_insn *cur = insn_start; in dump_xlated_for_graph()
|
/linux/kernel/bpf/ |
H A D | disasm.h | 25 const struct bpf_insn *insn); 27 const struct bpf_insn *insn, 38 const struct bpf_insn *insn,
|
H A D | disasm.c | 17 const struct bpf_insn *insn, in __func_get_name() 44 const struct bpf_insn *insn, in __func_imm_name() 140 const struct bpf_insn *insn) in print_bpf_end_insn() 150 const struct bpf_insn *insn) in print_bpf_bswap_insn() 157 static bool is_sdiv_smod(const struct bpf_insn *insn) in is_sdiv_smod() 163 static bool is_movsx(const struct bpf_insn *insn) in is_movsx() 169 static bool is_addr_space_cast(const struct bpf_insn *insn) in is_addr_space_cast() 181 static inline bool is_mov_percpu_addr(const struct bpf_insn *insn) in is_mov_percpu_addr() 187 const struct bpf_insn *insn, in print_bpf_insn()
|
/linux/tools/perf/util/ |
H A D | bpf-prologue.h | 10 struct bpf_insn; 18 struct bpf_insn *new_prog, size_t *new_cnt, 27 struct bpf_insn *new_prog __maybe_unused, in bpf__gen_prologue()
|
/linux/tools/testing/selftests/bpf/prog_tests/ |
H A D | kptr_xchg_inline.c | 11 struct bpf_insn *insn = NULL; in test_kptr_xchg_inline() 12 struct bpf_insn exp; in test_kptr_xchg_inline()
|
H A D | raw_tp_writable_test_run.c | 13 const struct bpf_insn trace_program[] = { in serial_test_raw_tp_writable_test_run() 34 const struct bpf_insn skb_program[] = { in serial_test_raw_tp_writable_test_run()
|
/linux/arch/riscv/kernel/ |
H A D | cfi.c | 80 struct bpf_insn; 84 const struct bpf_insn *insn);
|
/linux/drivers/net/ethernet/netronome/nfp/bpf/ |
H A D | main.h | 301 struct bpf_insn insn; 306 struct bpf_insn *paired_st; 462 struct bpf_insn insn = meta->insn; in is_mbpf_helper_call() 470 struct bpf_insn insn = meta->insn; in is_mbpf_pseudo_call() 571 struct bpf_insn *insn);
|
H A D | jit.c | 1297 const struct bpf_insn *insn = &meta->insn; in wrp_alu64_imm() 1328 const struct bpf_insn *insn = &meta->insn; in wrp_alu32_imm() 1361 const struct bpf_insn *insn = &meta->insn; in wrp_test_reg() 1402 const struct bpf_insn *insn = &meta->insn; in cmp_imm() 1439 const struct bpf_insn *insn = &meta->insn; in cmp_reg() 1505 const struct bpf_insn *insn = &meta->insn; in wrp_mul() 1838 const struct bpf_insn *insn = &meta->insn; in mov_reg64() 1901 const struct bpf_insn *insn = &meta->insn; in add_reg64() 1915 const struct bpf_insn *insn = &meta->insn; in add_imm64() 1926 const struct bpf_insn *insn = &meta->insn; in sub_reg64() [all …]
|
/linux/arch/loongarch/net/ |
H A D | bpf_jit.h | 47 static inline int bpf2la_offset(int bpf_insn, int off, const struct jit_ctx *ctx) in bpf2la_offset() argument 50 bpf_insn++; in bpf2la_offset() 56 return (ctx->offset[bpf_insn + off] - (ctx->offset[bpf_insn] - 1)); in bpf2la_offset()
|