diff options
author | Naveen N Rao <naveen@kernel.org> | 2024-10-30 12:38:42 +0530 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2024-10-31 11:00:54 +1100 |
commit | 9670f6d2097c4f97e15c67920dfddc664d7ee91c (patch) | |
tree | 603f43532a9698c1f7a513b4551848fd551f6241 /scripts | |
parent | ed6144656bb1ea29ad83671b48a21c89e7873b8a (diff) | |
download | linux-9670f6d2097c4f97e15c67920dfddc664d7ee91c.tar.gz linux-9670f6d2097c4f97e15c67920dfddc664d7ee91c.tar.bz2 linux-9670f6d2097c4f97e15c67920dfddc664d7ee91c.zip |
powerpc64/bpf: Fold bpf_jit_emit_func_call_hlp() into bpf_jit_emit_func_call_rel()
Commit 61688a82e047 ("powerpc/bpf: enable kfunc call") enhanced
bpf_jit_emit_func_call_hlp() to handle calls out to module region, where
bpf progs are generated. The only difference now between
bpf_jit_emit_func_call_hlp() and bpf_jit_emit_func_call_rel() is in
handling of the initial pass where target function address is not known.
Fold that logic into bpf_jit_emit_func_call_hlp() and rename it to
bpf_jit_emit_func_call_rel() to simplify bpf function call JIT code.
We don't actually need to load/restore TOC across a call out to a
different kernel helper or to a different bpf program since they all
work with the kernel TOC. We only need to do it if we have to call out
to a module function. So, guard TOC load/restore with appropriate
conditions.
Signed-off-by: Naveen N Rao <naveen@kernel.org>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://patch.msgid.link/20241030070850.1361304-10-hbathini@linux.ibm.com
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions