diff options
| author | George Guo <guodongtai@kylinos.cn> | 2026-08-17 22:07:40 +0800 |
|---|---|---|
| committer | Huacai Chen <chenhuacai@loongson.cn> | 2026-08-17 22:07:40 +0800 |
| commit | 1db6d003e93d033fca25bcfbef73e2780a7e46d7 (patch) | |
| tree | 4462d0110235287545d95275a7cd473aa90e1b01 /scripts/objdiff | |
| parent | 1fec6bbc09e3066a0f39d85741df2a7877c97945 (diff) | |
| download | linux-1db6d003e93d033fca25bcfbef73e2780a7e46d7.tar.gz linux-1db6d003e93d033fca25bcfbef73e2780a7e46d7.zip | |
LoongArch: BPF: Resolve per-CPU addrs for internal-only MOV
Add support for the internal-only BPF_MOV instruction that resolves the
absolute addresses of the per-CPU data from their per-CPU offsets. This
instruction is used only for internal inlining optimizations between the
BPF verifier and the JITs (e.g. inlining bpf_get_smp_processor_id() and
per-CPU map lookups).
LoongArch keeps the per-CPU offset of the current CPU in $r21 register
(a.k.a. __my_cpu_offset), so resolving a per-CPU address only requires
adding $r21 to the source register holding the per-CPU offset. Advertise
the capability via bpf_jit_supports_percpu_insn().
Acked-by: Tiezhu Yang <yangtiezhu@loongson.cn>
Tested-by: Tiezhu Yang <yangtiezhu@loongson.cn>
Signed-off-by: George Guo <guodongtai@kylinos.cn>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
Diffstat (limited to 'scripts/objdiff')
0 files changed, 0 insertions, 0 deletions
