Re: [PATCH bpf-next v3 3/6] bpf: Add a bpf_snprintf helper

From: Florent Revest
Date: Wed Apr 14 2021 - 09:32:51 EST


On Mon, Apr 12, 2021 at 10:32 PM kernel test robot <lkp@xxxxxxxxx> wrote:
> m68k-linux-ld: kernel/bpf/verifier.o: in function `check_helper_call.isra.0':
> >> verifier.c:(.text+0xf79e): undefined reference to `bpf_printf_prepare'
> m68k-linux-ld: kernel/bpf/helpers.o: in function `bpf_base_func_proto':
> >> helpers.c:(.text+0xd82): undefined reference to `bpf_snprintf_proto'

I'll move the implementation of bpf_printf_prepare/bpf_printf_cleanup
and bpf_snprintf to kernel/bpf/helpers.c so that they all get built on
kernels with CONFIG_BPF_SYSCALL but not CONFIG_BPF_EVENTS.