Home
last modified time | relevance | path

Searched refs:bpf_size (Results 1 – 7 of 7) sorted by relevance

/linux-6.15/net/sched/
H A Dact_bpf.c192 u16 bpf_size, bpf_num_ops; in tcf_bpf_init_from_ops() local
199 bpf_size = bpf_num_ops * sizeof(*bpf_ops); in tcf_bpf_init_from_ops()
200 if (bpf_size != nla_len(tb[TCA_ACT_BPF_OPS])) in tcf_bpf_init_from_ops()
203 bpf_ops = kmemdup(nla_data(tb[TCA_ACT_BPF_OPS]), bpf_size, GFP_KERNEL); in tcf_bpf_init_from_ops()
H A Dcls_bpf.c344 u16 bpf_size, bpf_num_ops; in cls_bpf_prog_from_ops() local
351 bpf_size = bpf_num_ops * sizeof(*bpf_ops); in cls_bpf_prog_from_ops()
352 if (bpf_size != nla_len(tb[TCA_BPF_OPS])) in cls_bpf_prog_from_ops()
355 bpf_ops = kmemdup(nla_data(tb[TCA_BPF_OPS]), bpf_size, GFP_KERNEL); in cls_bpf_prog_from_ops()
/linux-6.15/include/linux/
H A Dfilter.h524 int bpf_size = -EINVAL; \
527 bpf_size = BPF_B; \
529 bpf_size = BPF_H; \
531 bpf_size = BPF_W; \
533 bpf_size = BPF_DW; \
535 bpf_size; \
538 #define bpf_size_to_bytes(bpf_size) \ argument
542 if (bpf_size == BPF_B) \
544 else if (bpf_size == BPF_H) \
546 else if (bpf_size == BPF_W) \
[all …]
/linux-6.15/arch/x86/net/
H A Dbpf_jit_comp.c136 static int bpf_size_to_x86_bytes(int bpf_size) in bpf_size_to_x86_bytes() argument
138 if (bpf_size == BPF_W) in bpf_size_to_x86_bytes()
140 else if (bpf_size == BPF_H) in bpf_size_to_x86_bytes()
142 else if (bpf_size == BPF_B) in bpf_size_to_x86_bytes()
144 else if (bpf_size == BPF_DW) in bpf_size_to_x86_bytes()
1259 u32 dst_reg, u32 src_reg, s16 off, u8 bpf_size) in emit_atomic_rmw() argument
1265 maybe_emit_mod(&prog, dst_reg, src_reg, bpf_size == BPF_DW); in emit_atomic_rmw()
1349 u32 src_reg, s16 off, u8 bpf_size) in emit_atomic_ld_st() argument
1354 emit_ldx(pprog, bpf_size, dst_reg, src_reg, off); in emit_atomic_ld_st()
1358 emit_stx(pprog, bpf_size, dst_reg, src_reg, off); in emit_atomic_ld_st()
H A Dbpf_jit_comp32.c1172 static int bpf_size_to_x86_bytes(int bpf_size) in bpf_size_to_x86_bytes() argument
1174 if (bpf_size == BPF_W) in bpf_size_to_x86_bytes()
1176 else if (bpf_size == BPF_H) in bpf_size_to_x86_bytes()
1178 else if (bpf_size == BPF_B) in bpf_size_to_x86_bytes()
1180 else if (bpf_size == BPF_DW) in bpf_size_to_x86_bytes()
/linux-6.15/tools/perf/util/
H A Ddso.c867 static int bpf_size(struct dso *dso) in bpf_size() function
1139 return bpf_size(dso); in dso__data_file_size()
/linux-6.15/kernel/bpf/
H A Dverifier.c7411 int off, int bpf_size, enum bpf_access_type t, in check_mem_access() argument
7418 size = bpf_size_to_bytes(bpf_size); in check_mem_access()