static void bpf_trampoline_restore_tail_call_cnt(u32 *image, struct codegen_context *ctx,
int func_frame_offset, int r4_off)
{
- if (IS_ENABLED(CONFIG_PPC64)) {
- /* See bpf_jit_stack_tailcallcnt() */
- int tailcallcnt_offset = BPF_PPC_TAILCALL;
-
- EMIT(PPC_RAW_LL(_R3, _R1, -tailcallcnt_offset));
- EMIT(PPC_RAW_STL(_R3, _R1, func_frame_offset - tailcallcnt_offset));
- } else {
- /* See bpf_jit_stack_offsetof() and BPF_PPC_TC */
+ if (IS_ENABLED(CONFIG_PPC32)) {
+ /*
+ * Restore tailcall for 32-bit powerpc
+ * See bpf_jit_stack_offsetof() and BPF_PPC_TC
+ */
EMIT(PPC_RAW_STL(_R4, _R1, r4_off));
}
}