summaryrefslogtreecommitdiff
path: root/kernel/bpf/core.c
diff options
context:
space:
mode:
authorPu Lehui <pulehui@huawei.com>2023-07-21 18:06:27 +0800
committerAlexei Starovoitov <ast@kernel.org>2023-08-02 14:03:56 -0700
commit25ad10658dc1068a671553ff10e19a812c2a3783 (patch)
tree878a2da2472ca097e1ddbd6c87b25ca5c0b94167 /kernel/bpf/core.c
parent94e38c956b97d3bb3f6cc8215efb13ea851e3a91 (diff)
riscv, bpf: Adapt bpf trampoline to optimized riscv ftrace framework
Commit 6724a76cff85 ("riscv: ftrace: Reduce the detour code size to half") optimizes the detour code size of kernel functions to half with T0 register and the upcoming DYNAMIC_FTRACE_WITH_DIRECT_CALLS of riscv is based on this optimization, we need to adapt riscv bpf trampoline based on this. One thing to do is to reduce detour code size of bpf programs, and the second is to deal with the return address after the execution of bpf trampoline. Meanwhile, we need to construct the frame of parent function, otherwise we will miss one layer when unwinding. The related tests have passed. Signed-off-by: Pu Lehui <pulehui@huawei.com> Tested-by: Björn Töpel <bjorn@rivosinc.com> Link: https://lore.kernel.org/r/20230721100627.2630326-1-pulehui@huaweicloud.com Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'kernel/bpf/core.c')
0 files changed, 0 insertions, 0 deletions