Skip to content
Commit 2cd3e377 authored by Peter Zijlstra's avatar Peter Zijlstra Committed by Alexei Starovoitov
Browse files

x86/cfi,bpf: Fix bpf_struct_ops CFI



BPF struct_ops uses __arch_prepare_bpf_trampoline() to write
trampolines for indirect function calls. These tramplines much have
matching CFI.

In order to obtain the correct CFI hash for the various methods, add a
matching structure that contains stub functions, the compiler will
generate correct CFI which we can pilfer for the trampolines.

Signed-off-by: default avatarPeter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lore.kernel.org/r/20231215092707.566977112@infradead.org


Signed-off-by: default avatarAlexei Starovoitov <ast@kernel.org>
parent e72d88d1
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment