| /linux-6.15/arch/powerpc/net/ |
| H A D | bpf_jit_comp64.c | 402 u32 dst_reg = bpf_to_ppc(insn[i].dst_reg); in bpf_jit_build_body() local 445 EMIT(PPC_RAW_ADD(dst_reg, dst_reg, src_reg)); in bpf_jit_build_body() 449 EMIT(PPC_RAW_SUB(dst_reg, dst_reg, src_reg)); in bpf_jit_build_body() 572 EMIT(PPC_RAW_NEG(dst_reg, dst_reg)); in bpf_jit_build_body() 594 EMIT(PPC_RAW_OR(dst_reg, dst_reg, src_reg)); in bpf_jit_build_body() 638 EMIT(PPC_RAW_SLWI(dst_reg, dst_reg, imm)); in bpf_jit_build_body() 644 EMIT(PPC_RAW_SLDI(dst_reg, dst_reg, imm)); in bpf_jit_build_body() 655 EMIT(PPC_RAW_SRWI(dst_reg, dst_reg, imm)); in bpf_jit_build_body() 661 EMIT(PPC_RAW_SRDI(dst_reg, dst_reg, imm)); in bpf_jit_build_body() 670 EMIT(PPC_RAW_SRAWI(dst_reg, dst_reg, imm)); in bpf_jit_build_body() [all …]
|
| H A D | bpf_jit_comp32.c | 300 u32 dst_reg = bpf_to_ppc(insn[i].dst_reg); in bpf_jit_build_body() local 344 if (dst_reg >= 3 && dst_reg < 32) { in bpf_jit_build_body() 531 EMIT(PPC_RAW_SUBFC(dst_reg, dst_reg_h, dst_reg)); in bpf_jit_build_body() 533 EMIT(PPC_RAW_XOR(dst_reg, dst_reg, dst_reg_h)); in bpf_jit_build_body() 534 EMIT(PPC_RAW_SUBFC(dst_reg, dst_reg_h, dst_reg)); in bpf_jit_build_body() 692 EMIT(PPC_RAW_OR(dst_reg, dst_reg, _R0)); in bpf_jit_build_body() 694 EMIT(PPC_RAW_OR(dst_reg, dst_reg, tmp_reg)); in bpf_jit_build_body() 729 EMIT(PPC_RAW_OR(dst_reg, dst_reg, _R0)); in bpf_jit_build_body() 734 EMIT(PPC_RAW_OR(dst_reg, dst_reg, tmp_reg)); in bpf_jit_build_body() 810 EMIT(PPC_RAW_RLWINM(dst_reg, dst_reg, 24, 16, 31)); in bpf_jit_build_body() [all …]
|
| /linux-6.15/tools/include/linux/ |
| H A D | filter.h | 37 .dst_reg = DST, \ 45 .dst_reg = DST, \ 55 .dst_reg = DST, \ 63 .dst_reg = DST, \ 73 .dst_reg = DST, \ 83 .dst_reg = DST, \ 91 .dst_reg = DST, \ 101 .dst_reg = DST, \ 155 .dst_reg = 0, \ 165 .dst_reg = 0, \ [all …]
|
| /linux-6.15/arch/x86/net/ |
| H A D | bpf_jit_comp.c | 925 EMIT1(add_2mod(0x40, dst_reg, dst_reg)); in emit_mov_imm32() 928 EMIT2(b2, add_2reg(b3, dst_reg, dst_reg)); in emit_mov_imm32() 1476 EMIT2(0xf7, add_2reg(0xC0, dst_reg, dst_reg)); in emit_shiftx() 1616 u32 dst_reg = insn->dst_reg; in do_jit() local 1677 EMIT2(0x85, add_2reg(0xC0, dst_reg, dst_reg)); in do_jit() 1847 maybe_emit_mod(&prog, dst_reg, dst_reg, in do_jit() 1852 EMIT3(0x6B, add_2reg(0xC0, dst_reg, dst_reg), in do_jit() 1857 add_2reg(0xC0, dst_reg, dst_reg), in do_jit() 1961 EMIT1(add_2reg(0xC0, dst_reg, dst_reg)); in do_jit() 1990 EMIT1(add_2reg(0xC0, dst_reg, dst_reg)); in do_jit() [all …]
|
| /linux-6.15/arch/s390/net/ |
| H A D | bpf_jit_comp.c | 863 u32 dst_reg = insn->dst_reg; in bpf_jit_insn() local 891 EMIT4(0xb9160000, dst_reg, dst_reg); in bpf_jit_insn() 897 EMIT4(0xb9160000, dst_reg, dst_reg); in bpf_jit_insn() 1398 EMIT2(0x1300, dst_reg, dst_reg); in bpf_jit_insn() 1403 EMIT4(0xb9030000, dst_reg, dst_reg); in bpf_jit_insn() 1413 EMIT4(0xb9850000, dst_reg, dst_reg); in bpf_jit_insn() 1420 EMIT4(0xb9160000, dst_reg, dst_reg); in bpf_jit_insn() 1431 EMIT4(0xb91f0000, dst_reg, dst_reg); in bpf_jit_insn() 1435 EMIT4(0xb9850000, dst_reg, dst_reg); in bpf_jit_insn() 1441 EMIT4(0xb91f0000, dst_reg, dst_reg); in bpf_jit_insn() [all …]
|
| /linux-6.15/samples/bpf/ |
| H A D | bpf_insn.h | 13 .dst_reg = DST, \ 21 .dst_reg = DST, \ 31 .dst_reg = DST, \ 39 .dst_reg = DST, \ 49 .dst_reg = DST, \ 57 .dst_reg = DST, \ 67 .dst_reg = DST, \ 75 .dst_reg = DST, \ 87 .dst_reg = DST, \ 93 .dst_reg = 0, \ [all …]
|
| /linux-6.15/tools/testing/selftests/bpf/ |
| H A D | disasm.c | 143 insn->code, insn->dst_reg, in print_bpf_end_insn() 145 insn->imm, insn->dst_reg); in print_bpf_end_insn() 153 insn->code, insn->dst_reg, in print_bpf_bswap_insn() 154 insn->imm, insn->dst_reg); in print_bpf_bswap_insn() 203 insn->dst_reg); in print_bpf_insn() 214 insn->dst_reg, in print_bpf_insn() 223 insn->dst_reg, in print_bpf_insn() 233 insn->dst_reg, in print_bpf_insn() 290 insn->dst_reg, in print_bpf_insn() 374 insn->dst_reg, in print_bpf_insn() [all …]
|
| /linux-6.15/kernel/bpf/ |
| H A D | disasm.c | 143 insn->code, insn->dst_reg, in print_bpf_end_insn() 145 insn->imm, insn->dst_reg); in print_bpf_end_insn() 153 insn->code, insn->dst_reg, in print_bpf_bswap_insn() 154 insn->imm, insn->dst_reg); in print_bpf_bswap_insn() 203 insn->dst_reg); in print_bpf_insn() 214 insn->dst_reg, in print_bpf_insn() 223 insn->dst_reg, in print_bpf_insn() 233 insn->dst_reg, in print_bpf_insn() 290 insn->dst_reg, in print_bpf_insn() 374 insn->dst_reg, in print_bpf_insn() [all …]
|
| H A D | verifier.c | 14259 dst_reg->off + dst_reg->var_off.value)) in sanitize_check_bounds() 14708 dst_reg->smin_value = dst_reg->umin_value; in scalar_min_max_and() 14709 dst_reg->smax_value = dst_reg->umax_value; in scalar_min_max_and() 14765 dst_reg->umax_value = dst_reg->var_off.value | dst_reg->var_off.mask; in scalar_min_max_or() 14771 dst_reg->smin_value = dst_reg->umin_value; in scalar_min_max_or() 14772 dst_reg->smax_value = dst_reg->umax_value; in scalar_min_max_or() 14823 dst_reg->umax_value = dst_reg->var_off.value | dst_reg->var_off.mask; in scalar_min_max_xor() 15188 dst_reg = ®s[insn->dst_reg]; in adjust_reg_min_max_vals() 16419 dst_reg = ®s[insn->dst_reg]; in check_cond_jmp_op() 16631 dst_reg = ®s[insn->dst_reg]; in check_ld_imm() [all …]
|
| H A D | cgroup.c | 2287 BPF_DW, si->dst_reg, treg, in sysctl_convert_ctx_access() 2291 treg, si->dst_reg, in sysctl_convert_ctx_access() 2300 BPF_DW, treg, si->dst_reg, in sysctl_convert_ctx_access() 2305 si->dst_reg, si->src_reg, in sysctl_convert_ctx_access() 2309 BPF_SIZE(si->code), si->dst_reg, si->dst_reg, in sysctl_convert_ctx_access() 2450 si->dst_reg, si->src_reg, \ 2456 si->dst_reg, si->src_reg, \ 2503 treg, si->dst_reg, in cg_sockopt_convert_ctx_access() 2517 si->dst_reg, si->src_reg, in cg_sockopt_convert_ctx_access() 2520 si->dst_reg, si->dst_reg, in cg_sockopt_convert_ctx_access() [all …]
|
| H A D | core.c | 59 #define DST regs[insn->dst_reg] 324 dst[i].dst_reg == 0 && in bpf_prog_calc_tag() 1322 if (from->dst_reg == BPF_REG_AX || from->src_reg == BPF_REG_AX) in bpf_jit_blind_insn() 1328 *to++ = BPF_ALU64_REG(BPF_XOR, from->dst_reg, from->dst_reg); in bpf_jit_blind_insn() 1344 *to++ = BPF_ALU32_REG_OFF(from->code, from->dst_reg, BPF_REG_AX, from->off); in bpf_jit_blind_insn() 1358 *to++ = BPF_ALU64_REG_OFF(from->code, from->dst_reg, BPF_REG_AX, from->off); in bpf_jit_blind_insn() 1378 *to++ = BPF_JMP_REG(from->code, from->dst_reg, BPF_REG_AX, off); in bpf_jit_blind_insn() 1398 *to++ = BPF_JMP32_REG(from->code, from->dst_reg, BPF_REG_AX, in bpf_jit_blind_insn() 1406 *to++ = BPF_ALU64_REG(BPF_MOV, aux[0].dst_reg, BPF_REG_AX); in bpf_jit_blind_insn() 1413 *to++ = BPF_ALU64_REG(BPF_OR, aux[0].dst_reg, BPF_REG_AX); in bpf_jit_blind_insn() [all …]
|
| /linux-6.15/net/core/ |
| H A D | filter.c | 9814 *insn++ = BPF_MOV64_REG(si->dst_reg, si->dst_reg); in bpf_convert_ctx_access() 9949 si->dst_reg, si->dst_reg, in bpf_convert_ctx_access() 9957 si->dst_reg, si->dst_reg, in bpf_convert_ctx_access() 9984 si->dst_reg, si->dst_reg, in bpf_convert_ctx_access() 10221 si->dst_reg, si->dst_reg, in xdp_convert_ctx_access() 10239 si->dst_reg, si->dst_reg, in xdp_convert_ctx_access() 10264 SIZE, si->dst_reg, si->dst_reg, \ 10449 si->dst_reg, si->dst_reg, \ in sock_ops_convert_ctx_access() 10800 si->dst_reg, si->dst_reg, in sock_ops_convert_ctx_access() 10811 si->dst_reg, si->dst_reg, in sock_ops_convert_ctx_access() [all …]
|
| /linux-6.15/drivers/net/ethernet/netronome/nfp/bpf/ |
| H A D | jit.c | 1329 u8 dst = insn->dst_reg * 2; in wrp_alu32_imm() 1406 u8 reg = insn->dst_reg * 2; in cmp_imm() 1447 areg = insn->dst_reg * 2; in cmp_reg() 1507 u8 dst_reg; in wrp_mul() local 1509 dst_reg = insn->dst_reg; in wrp_mul() 2064 dst = insn->dst_reg * 2; in shl_reg64() 2176 dst = insn->dst_reg * 2; in shr_reg64() 2293 dst = insn->dst_reg * 2; in ashr_reg64() 2448 dst = insn->dst_reg * 2; in ashr_reg() 2499 dst = insn->dst_reg * 2; in shr_reg() [all …]
|
| H A D | verifier.c | 505 const struct bpf_reg_state *reg = cur_regs(env) + meta->insn.dst_reg; in nfp_bpf_check_store() 522 return nfp_bpf_check_ptr(nfp_prog, meta, env, meta->insn.dst_reg); in nfp_bpf_check_store() 530 const struct bpf_reg_state *dreg = cur_regs(env) + meta->insn.dst_reg; in nfp_bpf_check_atomic() 552 return nfp_bpf_check_ptr(nfp_prog, meta, env, meta->insn.dst_reg); in nfp_bpf_check_atomic() 562 cur_regs(env) + meta->insn.dst_reg; in nfp_bpf_check_alu() 647 meta->insn.dst_reg >= MAX_BPF_REG) { in nfp_verify_insn() 684 if (meta->insn.dst_reg >= BPF_REG_6 && in nfp_assign_subprog_idx_and_regs() 685 meta->insn.dst_reg <= BPF_REG_9) in nfp_assign_subprog_idx_and_regs()
|
| /linux-6.15/include/linux/ |
| H A D | filter.h | 105 .dst_reg = DST, \ 116 .dst_reg = DST, \ 129 .dst_reg = DST, \ 139 .dst_reg = DST, \ 276 .dst_reg = 0, \ 308 .dst_reg = 0, \ 318 .dst_reg = 0, \ 437 .dst_reg = 0, \ 447 .dst_reg = 0, \ 457 .dst_reg = 0, \ [all …]
|
| /linux-6.15/tools/testing/selftests/bpf/verifier/ |
| H A D | atomic_fetch.c | 95 #define __ATOMIC_FETCH_OP_TEST(src_reg, dst_reg, operand1, op, operand2, expect) \ argument 97 "atomic fetch " #op ", src=" #dst_reg " dst=" #dst_reg, \ 102 BPF_MOV64_REG(dst_reg, BPF_REG_10), \ 105 dst_reg, src_reg, -8), \
|
| /linux-6.15/drivers/scsi/ |
| H A D | script_asm.pl | 553 $dst_reg = "\U$1\E"; 581 print STDERR "source = $src_reg, data = $data8 , destination = $dst_reg\n" 585 if (($src_reg eq undef) || ($src_reg eq $dst_reg)) { 587 ($registers{$dst_reg} << 16); 588 } elsif ($dst_reg =~ /SFBR/i) { 593 ($registers{$dst_reg} << 16);
|
| /linux-6.15/arch/arm64/lib/ |
| H A D | crc-t10dif-core.S | 199 .macro fold_16_bytes, p, src_reg, dst_reg, load_next_consts 204 eor \dst_reg\().16b, \dst_reg\().16b, v8.16b 205 eor \dst_reg\().16b, \dst_reg\().16b, \src_reg\().16b
|
| /linux-6.15/drivers/gpu/drm/i915/gem/ |
| H A D | i915_gem_ttm_move.c | 318 struct intel_memory_region *dst_reg, *src_reg; in i915_ttm_memcpy_init() local 320 dst_reg = i915_ttm_region(bo->bdev, dst_mem->mem_type); in i915_ttm_memcpy_init() 322 GEM_BUG_ON(!dst_reg || !src_reg); in i915_ttm_memcpy_init() 326 ttm_kmap_iter_iomap_init(&arg->_dst_iter.io, &dst_reg->iomap, in i915_ttm_memcpy_init() 327 &dst_rsgt->table, dst_reg->region.start); in i915_ttm_memcpy_init()
|
| /linux-6.15/arch/arm/lib/ |
| H A D | crc-t10dif-core.S | 215 .macro fold_16_bytes, src_reg, dst_reg, p, load_next_consts 220 veor.8 \dst_reg, \dst_reg, \src_reg
|
| /linux-6.15/tools/testing/selftests/bpf/progs/ |
| H A D | netif_receive_skb.c | 241 {.code = (__u8)1,.dst_reg = (__u8)0x2,.src_reg = (__u8)0x3,.off = (__s16)4,.imm = (__s32)5,}); in BPF_PROG() 243 {.code = 1, .dst_reg = 0x2, .src_reg = 0x3, .off = 4, in BPF_PROG()
|
| /linux-6.15/arch/arm64/net/ |
| H A D | bpf_jit_comp.c | 359 if (insn->dst_reg == BPF_REG_6 || insn->src_reg == BPF_REG_6) in find_used_callee_regs() 659 const u8 dst = bpf2a64[insn->dst_reg]; in emit_atomic_ld_st() 732 const u8 dst = bpf2a64[insn->dst_reg]; in emit_lse_atomic() 804 const u8 dst = bpf2a64[insn->dst_reg]; in emit_ll_sc_atomic() 1025 int dst_reg = FIELD_GET(BPF_FIXUP_REG_MASK, ex->fixup); in ex_handler_bpf() local 1027 if (dst_reg != DONT_CLEAR) in ex_handler_bpf() 1028 regs->regs[dst_reg] = 0; in ex_handler_bpf() 1036 int dst_reg) in add_exception_handler() argument 1096 dst_reg = DONT_CLEAR; in add_exception_handler() 1099 FIELD_PREP(BPF_FIXUP_REG_MASK, dst_reg); in add_exception_handler() [all …]
|
| /linux-6.15/Documentation/bpf/ |
| H A D | classic_vs_extended.rst | 212 op:16, jt:8, jf:8, k:32 ==> op:8, dst_reg:4, src_reg:4, off:16, imm:32 325 In eBPF it means dst_reg = (u32) dst_reg + (u32) src_reg; similarly, 334 dst_reg = dst_reg + src_reg
|
| /linux-6.15/tools/testing/selftests/bpf/prog_tests/ |
| H A D | btf_dump.c | 794 {.code = (__u8)1,.dst_reg = (__u8)0x2,.src_reg = (__u8)0x3,.off = (__s16)4,.imm = (__s32)5,}); in test_btf_dump_struct_data() 798 { .code = 1, .dst_reg = 0x2, .src_reg = 0x3, .off = 4, in test_btf_dump_struct_data() 808 {.code = 1, .dst_reg = 2, .src_reg = 3, .off = 4, .imm = 5}); in test_btf_dump_struct_data() 813 { .code = 0, .dst_reg = 1}); in test_btf_dump_struct_data()
|
| /linux-6.15/arch/loongarch/net/ |
| H A D | bpf_jit.c | 291 const u8 dst = regmap[insn->dst_reg]; in emit_atomic() 403 int dst_reg = FIELD_GET(BPF_FIXUP_REG_MASK, ex->fixup); in ex_handler_bpf() local 406 regs->regs[dst_reg] = 0; in ex_handler_bpf() 415 int dst_reg) in add_exception_handler() argument 453 ex->fixup = FIELD_PREP(BPF_FIXUP_OFFSET_MASK, offset) | FIELD_PREP(BPF_FIXUP_REG_MASK, dst_reg); in add_exception_handler() 472 const u8 dst = regmap[insn->dst_reg]; in build_insn()
|